@codingame/monaco-vscode-standalone-languages 23.1.1 → 23.2.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/index.js +48 -82
- package/package.json +2 -2
- package/_.contribution.js +0 -74
- package/abap/abap.contribution.js +0 -19
- package/abap/abap.js +0 -1406
- package/apex/apex.contribution.js +0 -20
- package/apex/apex.js +0 -338
- package/azcli/azcli.contribution.js +0 -19
- package/azcli/azcli.js +0 -76
- package/bat/bat.contribution.js +0 -19
- package/bat/bat.js +0 -108
- package/bicep/bicep.contribution.js +0 -19
- package/bicep/bicep.js +0 -117
- package/cameligo/cameligo.contribution.js +0 -19
- package/cameligo/cameligo.js +0 -182
- package/clojure/clojure.contribution.js +0 -19
- package/clojure/clojure.js +0 -769
- package/coffee/coffee.contribution.js +0 -20
- package/coffee/coffee.js +0 -240
- package/cpp/cpp.contribution.js +0 -29
- package/cpp/cpp.js +0 -397
- package/csharp/csharp.contribution.js +0 -19
- package/csharp/csharp.js +0 -334
- package/csp/csp.contribution.js +0 -19
- package/csp/csp.js +0 -61
- package/css/css.contribution.js +0 -20
- package/css/css.js +0 -193
- package/cypher/cypher.contribution.js +0 -19
- package/cypher/cypher.js +0 -271
- package/dart/dart.contribution.js +0 -20
- package/dart/dart.js +0 -289
- package/dockerfile/dockerfile.contribution.js +0 -20
- package/dockerfile/dockerfile.js +0 -138
- package/ecl/ecl.contribution.js +0 -19
- package/ecl/ecl.js +0 -464
- package/elixir/elixir.contribution.js +0 -19
- package/elixir/elixir.js +0 -577
- package/flow9/flow9.contribution.js +0 -19
- package/flow9/flow9.js +0 -150
- package/freemarker2/freemarker2.contribution.js +0 -73
- package/freemarker2/freemarker2.js +0 -1016
- package/fsharp/fsharp.contribution.js +0 -19
- package/fsharp/fsharp.js +0 -225
- package/go/go.contribution.js +0 -19
- package/go/go.js +0 -226
- package/graphql/graphql.contribution.js +0 -20
- package/graphql/graphql.js +0 -159
- package/handlebars/handlebars.contribution.js +0 -20
- package/handlebars/handlebars.js +0 -439
- package/hcl/hcl.contribution.js +0 -19
- package/hcl/hcl.js +0 -191
- package/html/html.contribution.js +0 -20
- package/html/html.js +0 -328
- package/ini/ini.contribution.js +0 -20
- package/ini/ini.js +0 -79
- package/java/java.contribution.js +0 -20
- package/java/java.js +0 -240
- package/javascript/javascript.contribution.js +0 -22
- package/javascript/javascript.js +0 -77
- package/julia/julia.contribution.js +0 -19
- package/julia/julia.js +0 -519
- package/kotlin/kotlin.contribution.js +0 -20
- package/kotlin/kotlin.js +0 -261
- package/less/less.contribution.js +0 -20
- package/less/less.js +0 -169
- package/lexon/lexon.contribution.js +0 -19
- package/lexon/lexon.js +0 -165
- package/liquid/liquid.contribution.js +0 -20
- package/liquid/liquid.js +0 -260
- package/lua/lua.contribution.js +0 -19
- package/lua/lua.js +0 -170
- package/m3/m3.contribution.js +0 -19
- package/m3/m3.js +0 -218
- package/markdown/markdown.contribution.js +0 -19
- package/markdown/markdown.js +0 -237
- package/mdx/mdx.contribution.js +0 -19
- package/mdx/mdx.js +0 -184
- package/mips/mips.contribution.js +0 -20
- package/mips/mips.js +0 -206
- package/msdax/msdax.contribution.js +0 -19
- package/msdax/msdax.js +0 -383
- package/mysql/mysql.contribution.js +0 -19
- package/mysql/mysql.js +0 -886
- package/objective-c/objective-c.contribution.js +0 -19
- package/objective-c/objective-c.js +0 -191
- package/pascal/pascal.contribution.js +0 -20
- package/pascal/pascal.js +0 -259
- package/pascaligo/pascaligo.contribution.js +0 -19
- package/pascaligo/pascaligo.js +0 -172
- package/perl/perl.contribution.js +0 -19
- package/perl/perl.js +0 -634
- package/pgsql/pgsql.contribution.js +0 -19
- package/pgsql/pgsql.js +0 -859
- package/php/php.contribution.js +0 -20
- package/php/php.js +0 -508
- package/pla/pla.contribution.js +0 -18
- package/pla/pla.js +0 -145
- package/postiats/postiats.contribution.js +0 -19
- package/postiats/postiats.js +0 -915
- package/powerquery/powerquery.contribution.js +0 -19
- package/powerquery/powerquery.js +0 -898
- package/powershell/powershell.contribution.js +0 -19
- package/powershell/powershell.js +0 -247
- package/protobuf/protobuf.contribution.js +0 -19
- package/protobuf/protobuf.js +0 -428
- package/pug/pug.contribution.js +0 -19
- package/pug/pug.js +0 -410
- package/python/python.contribution.js +0 -20
- package/python/python.js +0 -320
- package/qsharp/qsharp.contribution.js +0 -19
- package/qsharp/qsharp.js +0 -309
- package/r/r.contribution.js +0 -19
- package/r/r.js +0 -251
- package/razor/razor.contribution.js +0 -20
- package/razor/razor.js +0 -570
- package/redis/redis.contribution.js +0 -19
- package/redis/redis.js +0 -310
- package/redshift/redshift.contribution.js +0 -19
- package/redshift/redshift.js +0 -817
- package/restructuredtext/restructuredtext.contribution.js +0 -19
- package/restructuredtext/restructuredtext.js +0 -182
- package/ruby/ruby.contribution.js +0 -20
- package/ruby/ruby.js +0 -519
- package/rust/rust.contribution.js +0 -19
- package/rust/rust.js +0 -351
- package/sb/sb.contribution.js +0 -19
- package/sb/sb.js +0 -123
- package/scala/scala.contribution.js +0 -20
- package/scala/scala.js +0 -378
- package/scheme/scheme.contribution.js +0 -19
- package/scheme/scheme.js +0 -116
- package/scss/scss.contribution.js +0 -20
- package/scss/scss.js +0 -268
- package/shell/shell.contribution.js +0 -19
- package/shell/shell.js +0 -229
- package/solidity/solidity.contribution.js +0 -19
- package/solidity/solidity.js +0 -1375
- package/sophia/sophia.contribution.js +0 -19
- package/sophia/sophia.js +0 -207
- package/sparql/sparql.contribution.js +0 -19
- package/sparql/sparql.js +0 -209
- package/sql/sql.contribution.js +0 -19
- package/sql/sql.js +0 -861
- package/st/st.contribution.js +0 -19
- package/st/st.js +0 -424
- package/swift/swift.contribution.js +0 -20
- package/swift/swift.js +0 -320
- package/systemverilog/systemverilog.contribution.js +0 -29
- package/systemverilog/systemverilog.js +0 -584
- package/tcl/tcl.contribution.js +0 -19
- package/tcl/tcl.js +0 -240
- package/twig/twig.contribution.js +0 -20
- package/twig/twig.js +0 -400
- package/typescript/typescript.contribution.js +0 -20
- package/typescript/typescript.js +0 -362
- package/typespec/typespec.contribution.js +0 -19
- package/typespec/typespec.js +0 -135
- package/vb/vb.contribution.js +0 -19
- package/vb/vb.js +0 -380
- package/wgsl/wgsl.contribution.js +0 -19
- package/wgsl/wgsl.js +0 -461
- package/xml/xml.contribution.js +0 -39
- package/xml/xml.js +0 -114
- package/yaml/yaml.contribution.js +0 -20
- package/yaml/yaml.js +0 -225
package/index.js
CHANGED
|
@@ -1,82 +1,48 @@
|
|
|
1
|
-
import 'monaco-editor';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
import './postiats/postiats.contribution.js';
|
|
50
|
-
import './powerquery/powerquery.contribution.js';
|
|
51
|
-
import './powershell/powershell.contribution.js';
|
|
52
|
-
import './protobuf/protobuf.contribution.js';
|
|
53
|
-
import './pug/pug.contribution.js';
|
|
54
|
-
import './python/python.contribution.js';
|
|
55
|
-
import './qsharp/qsharp.contribution.js';
|
|
56
|
-
import './r/r.contribution.js';
|
|
57
|
-
import './razor/razor.contribution.js';
|
|
58
|
-
import './redis/redis.contribution.js';
|
|
59
|
-
import './redshift/redshift.contribution.js';
|
|
60
|
-
import './restructuredtext/restructuredtext.contribution.js';
|
|
61
|
-
import './ruby/ruby.contribution.js';
|
|
62
|
-
import './rust/rust.contribution.js';
|
|
63
|
-
import './sb/sb.contribution.js';
|
|
64
|
-
import './scala/scala.contribution.js';
|
|
65
|
-
import './scheme/scheme.contribution.js';
|
|
66
|
-
import './scss/scss.contribution.js';
|
|
67
|
-
import './shell/shell.contribution.js';
|
|
68
|
-
import './solidity/solidity.contribution.js';
|
|
69
|
-
import './sophia/sophia.contribution.js';
|
|
70
|
-
import './sparql/sparql.contribution.js';
|
|
71
|
-
import './sql/sql.contribution.js';
|
|
72
|
-
import './st/st.contribution.js';
|
|
73
|
-
import './swift/swift.contribution.js';
|
|
74
|
-
import './systemverilog/systemverilog.contribution.js';
|
|
75
|
-
import './tcl/tcl.contribution.js';
|
|
76
|
-
import './twig/twig.contribution.js';
|
|
77
|
-
import './typescript/typescript.contribution.js';
|
|
78
|
-
import './typespec/typespec.contribution.js';
|
|
79
|
-
import './vb/vb.contribution.js';
|
|
80
|
-
import './wgsl/wgsl.contribution.js';
|
|
81
|
-
import './xml/xml.contribution.js';
|
|
82
|
-
import './yaml/yaml.contribution.js';
|
|
1
|
+
import { languages } from 'monaco-editor';
|
|
2
|
+
|
|
3
|
+
const languageDefinitions = {};
|
|
4
|
+
const lazyLanguageLoaders = {};
|
|
5
|
+
class LazyLanguageLoader {
|
|
6
|
+
static getOrCreate(languageId) {
|
|
7
|
+
if (!lazyLanguageLoaders[languageId]) {
|
|
8
|
+
lazyLanguageLoaders[languageId] = new LazyLanguageLoader(languageId);
|
|
9
|
+
}
|
|
10
|
+
return lazyLanguageLoaders[languageId];
|
|
11
|
+
}
|
|
12
|
+
constructor(languageId) {
|
|
13
|
+
this._languageId = languageId;
|
|
14
|
+
this._loadingTriggered = false;
|
|
15
|
+
this._lazyLoadPromise = new Promise((resolve, reject) => {
|
|
16
|
+
this._lazyLoadPromiseResolve = resolve;
|
|
17
|
+
this._lazyLoadPromiseReject = reject;
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
load() {
|
|
21
|
+
if (!this._loadingTriggered) {
|
|
22
|
+
this._loadingTriggered = true;
|
|
23
|
+
languageDefinitions[this._languageId].loader().then(
|
|
24
|
+
(mod) => this._lazyLoadPromiseResolve(mod),
|
|
25
|
+
(err) => this._lazyLoadPromiseReject(err)
|
|
26
|
+
);
|
|
27
|
+
}
|
|
28
|
+
return this._lazyLoadPromise;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
function registerLanguage(def) {
|
|
32
|
+
const languageId = def.id;
|
|
33
|
+
languageDefinitions[languageId] = def;
|
|
34
|
+
languages.register(def);
|
|
35
|
+
const lazyLanguageLoader = LazyLanguageLoader.getOrCreate(languageId);
|
|
36
|
+
languages.registerTokensProviderFactory(languageId, {
|
|
37
|
+
create: async () => {
|
|
38
|
+
const mod = await lazyLanguageLoader.load();
|
|
39
|
+
return mod.language;
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
languages.onLanguageEncountered(languageId, async () => {
|
|
43
|
+
const mod = await lazyLanguageLoader.load();
|
|
44
|
+
languages.setLanguageConfiguration(languageId, mod.conf);
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export { registerLanguage };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-standalone-languages",
|
|
3
|
-
"version": "23.
|
|
3
|
+
"version": "23.2.1",
|
|
4
4
|
"keywords": [],
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "CodinGame",
|
|
@@ -18,6 +18,6 @@
|
|
|
18
18
|
"module": "index.js",
|
|
19
19
|
"types": "index.d.ts",
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"monaco-editor": "npm:@codingame/monaco-vscode-editor-api@23.
|
|
21
|
+
"monaco-editor": "npm:@codingame/monaco-vscode-editor-api@23.2.1"
|
|
22
22
|
}
|
|
23
23
|
}
|
package/_.contribution.js
DELETED
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
import * as monaco_editor_core_star from 'monaco-editor';
|
|
2
|
-
|
|
3
|
-
/*!-----------------------------------------------------------------------------
|
|
4
|
-
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
5
|
-
* Version: 0.54.0(undefined)
|
|
6
|
-
* Released under the MIT license
|
|
7
|
-
* https://github.com/microsoft/monaco-editor/blob/main/LICENSE.txt
|
|
8
|
-
*-----------------------------------------------------------------------------*/
|
|
9
|
-
|
|
10
|
-
var __defProp = Object.defineProperty;
|
|
11
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
12
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
13
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
|
-
var __copyProps = (to, from, except, desc) => {
|
|
15
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
16
|
-
for (let key of __getOwnPropNames(from))
|
|
17
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
18
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
19
|
-
}
|
|
20
|
-
return to;
|
|
21
|
-
};
|
|
22
|
-
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget);
|
|
23
|
-
|
|
24
|
-
// src/fillers/monaco-editor-core.ts
|
|
25
|
-
var monaco_editor_core_exports = {};
|
|
26
|
-
__reExport(monaco_editor_core_exports, monaco_editor_core_star);
|
|
27
|
-
|
|
28
|
-
// src/basic-languages/_.contribution.ts
|
|
29
|
-
var languageDefinitions = {};
|
|
30
|
-
var lazyLanguageLoaders = {};
|
|
31
|
-
var LazyLanguageLoader = class _LazyLanguageLoader {
|
|
32
|
-
static getOrCreate(languageId) {
|
|
33
|
-
if (!lazyLanguageLoaders[languageId]) {
|
|
34
|
-
lazyLanguageLoaders[languageId] = new _LazyLanguageLoader(languageId);
|
|
35
|
-
}
|
|
36
|
-
return lazyLanguageLoaders[languageId];
|
|
37
|
-
}
|
|
38
|
-
constructor(languageId) {
|
|
39
|
-
this._languageId = languageId;
|
|
40
|
-
this._loadingTriggered = false;
|
|
41
|
-
this._lazyLoadPromise = new Promise((resolve, reject) => {
|
|
42
|
-
this._lazyLoadPromiseResolve = resolve;
|
|
43
|
-
this._lazyLoadPromiseReject = reject;
|
|
44
|
-
});
|
|
45
|
-
}
|
|
46
|
-
load() {
|
|
47
|
-
if (!this._loadingTriggered) {
|
|
48
|
-
this._loadingTriggered = true;
|
|
49
|
-
languageDefinitions[this._languageId].loader().then(
|
|
50
|
-
(mod) => this._lazyLoadPromiseResolve(mod),
|
|
51
|
-
(err) => this._lazyLoadPromiseReject(err)
|
|
52
|
-
);
|
|
53
|
-
}
|
|
54
|
-
return this._lazyLoadPromise;
|
|
55
|
-
}
|
|
56
|
-
};
|
|
57
|
-
function registerLanguage(def) {
|
|
58
|
-
const languageId = def.id;
|
|
59
|
-
languageDefinitions[languageId] = def;
|
|
60
|
-
monaco_editor_core_exports.languages.register(def);
|
|
61
|
-
const lazyLanguageLoader = LazyLanguageLoader.getOrCreate(languageId);
|
|
62
|
-
monaco_editor_core_exports.languages.registerTokensProviderFactory(languageId, {
|
|
63
|
-
create: async () => {
|
|
64
|
-
const mod = await lazyLanguageLoader.load();
|
|
65
|
-
return mod.language;
|
|
66
|
-
}
|
|
67
|
-
});
|
|
68
|
-
monaco_editor_core_exports.languages.onLanguageEncountered(languageId, async () => {
|
|
69
|
-
const mod = await lazyLanguageLoader.load();
|
|
70
|
-
monaco_editor_core_exports.languages.setLanguageConfiguration(languageId, mod.conf);
|
|
71
|
-
});
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
export { registerLanguage };
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { registerLanguage } from '../_.contribution.js';
|
|
2
|
-
|
|
3
|
-
/*!-----------------------------------------------------------------------------
|
|
4
|
-
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
5
|
-
* Version: 0.54.0(undefined)
|
|
6
|
-
* Released under the MIT license
|
|
7
|
-
* https://github.com/microsoft/monaco-editor/blob/main/LICENSE.txt
|
|
8
|
-
*-----------------------------------------------------------------------------*/
|
|
9
|
-
|
|
10
|
-
registerLanguage({
|
|
11
|
-
id: "abap",
|
|
12
|
-
extensions: [".abap"],
|
|
13
|
-
aliases: ["abap", "ABAP"],
|
|
14
|
-
loader: () => {
|
|
15
|
-
{
|
|
16
|
-
return import('./abap.js');
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
});
|