mudlet-map-editor 0.7.1 → 0.10.0

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.
@@ -0,0 +1,272 @@
1
+ import { h as e } from "./editor.api2-PX2PsJx9.js";
2
+ //#region node_modules/monaco-editor/esm/vs/basic-languages/typescript/typescript.js
3
+ var t = {
4
+ wordPattern: /(-?\d*\.\d\w*)|([^\`\~\!\@\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,
5
+ comments: {
6
+ lineComment: "//",
7
+ blockComment: ["/*", "*/"]
8
+ },
9
+ brackets: [
10
+ ["{", "}"],
11
+ ["[", "]"],
12
+ ["(", ")"]
13
+ ],
14
+ onEnterRules: [
15
+ {
16
+ beforeText: /^\s*\/\*\*(?!\/)([^\*]|\*(?!\/))*$/,
17
+ afterText: /^\s*\*\/$/,
18
+ action: {
19
+ indentAction: e.IndentAction.IndentOutdent,
20
+ appendText: " * "
21
+ }
22
+ },
23
+ {
24
+ beforeText: /^\s*\/\*\*(?!\/)([^\*]|\*(?!\/))*$/,
25
+ action: {
26
+ indentAction: e.IndentAction.None,
27
+ appendText: " * "
28
+ }
29
+ },
30
+ {
31
+ beforeText: /^(\t|(\ \ ))*\ \*(\ ([^\*]|\*(?!\/))*)?$/,
32
+ action: {
33
+ indentAction: e.IndentAction.None,
34
+ appendText: "* "
35
+ }
36
+ },
37
+ {
38
+ beforeText: /^(\t|(\ \ ))*\ \*\/\s*$/,
39
+ action: {
40
+ indentAction: e.IndentAction.None,
41
+ removeText: 1
42
+ }
43
+ }
44
+ ],
45
+ autoClosingPairs: [
46
+ {
47
+ open: "{",
48
+ close: "}"
49
+ },
50
+ {
51
+ open: "[",
52
+ close: "]"
53
+ },
54
+ {
55
+ open: "(",
56
+ close: ")"
57
+ },
58
+ {
59
+ open: "\"",
60
+ close: "\"",
61
+ notIn: ["string"]
62
+ },
63
+ {
64
+ open: "'",
65
+ close: "'",
66
+ notIn: ["string", "comment"]
67
+ },
68
+ {
69
+ open: "`",
70
+ close: "`",
71
+ notIn: ["string", "comment"]
72
+ },
73
+ {
74
+ open: "/**",
75
+ close: " */",
76
+ notIn: ["string"]
77
+ }
78
+ ],
79
+ folding: { markers: {
80
+ start: /* @__PURE__ */ RegExp("^\\s*//\\s*#?region\\b"),
81
+ end: /* @__PURE__ */ RegExp("^\\s*//\\s*#?endregion\\b")
82
+ } }
83
+ }, n = {
84
+ defaultToken: "invalid",
85
+ tokenPostfix: ".ts",
86
+ keywords: /* @__PURE__ */ "abstract.any.as.asserts.bigint.boolean.break.case.catch.class.continue.const.constructor.debugger.declare.default.delete.do.else.enum.export.extends.false.finally.for.from.function.get.if.implements.import.in.infer.instanceof.interface.is.keyof.let.module.namespace.never.new.null.number.object.out.package.private.protected.public.override.readonly.require.global.return.satisfies.set.static.string.super.switch.symbol.this.throw.true.try.type.typeof.undefined.unique.unknown.var.void.while.with.yield.async.await.of".split("."),
87
+ operators: /* @__PURE__ */ "<=.>=.==.!=.===.!==.=>.+.-.**.*./.%.++.--.<<.</.>>.>>>.&.|.^.!.~.&&.||.??.?.:.=.+=.-=.*=.**=./=.%=.<<=.>>=.>>>=.&=.|=.^=.@".split("."),
88
+ symbols: /[=><!~?:&|+\-*\/\^%]+/,
89
+ escapes: /\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,
90
+ digits: /\d+(_+\d+)*/,
91
+ octaldigits: /[0-7]+(_+[0-7]+)*/,
92
+ binarydigits: /[0-1]+(_+[0-1]+)*/,
93
+ hexdigits: /[[0-9a-fA-F]+(_+[0-9a-fA-F]+)*/,
94
+ regexpctl: /[(){}\[\]\$\^|\-*+?\.]/,
95
+ regexpesc: /\\(?:[bBdDfnrstvwWn0\\\/]|@regexpctl|c[A-Z]|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4})/,
96
+ tokenizer: {
97
+ root: [[/[{}]/, "delimiter.bracket"], { include: "common" }],
98
+ common: [
99
+ [/#?[a-z_$][\w$]*/, { cases: {
100
+ "@keywords": "keyword",
101
+ "@default": "identifier"
102
+ } }],
103
+ [/[A-Z][\w\$]*/, "type.identifier"],
104
+ { include: "@whitespace" },
105
+ [/\/(?=([^\\\/]|\\.)+\/([dgimsuy]*)(\s*)(\.|;|,|\)|\]|\}|$))/, {
106
+ token: "regexp",
107
+ bracket: "@open",
108
+ next: "@regexp"
109
+ }],
110
+ [/[()\[\]]/, "@brackets"],
111
+ [/[<>](?!@symbols)/, "@brackets"],
112
+ [/!(?=([^=]|$))/, "delimiter"],
113
+ [/@symbols/, { cases: {
114
+ "@operators": "delimiter",
115
+ "@default": ""
116
+ } }],
117
+ [/(@digits)[eE]([\-+]?(@digits))?/, "number.float"],
118
+ [/(@digits)\.(@digits)([eE][\-+]?(@digits))?/, "number.float"],
119
+ [/0[xX](@hexdigits)n?/, "number.hex"],
120
+ [/0[oO]?(@octaldigits)n?/, "number.octal"],
121
+ [/0[bB](@binarydigits)n?/, "number.binary"],
122
+ [/(@digits)n?/, "number"],
123
+ [/[;,.]/, "delimiter"],
124
+ [/"([^"\\]|\\.)*$/, "string.invalid"],
125
+ [/'([^'\\]|\\.)*$/, "string.invalid"],
126
+ [
127
+ /"/,
128
+ "string",
129
+ "@string_double"
130
+ ],
131
+ [
132
+ /'/,
133
+ "string",
134
+ "@string_single"
135
+ ],
136
+ [
137
+ /`/,
138
+ "string",
139
+ "@string_backtick"
140
+ ]
141
+ ],
142
+ whitespace: [
143
+ [/[ \t\r\n]+/, ""],
144
+ [
145
+ /\/\*\*(?!\/)/,
146
+ "comment.doc",
147
+ "@jsdoc"
148
+ ],
149
+ [
150
+ /\/\*/,
151
+ "comment",
152
+ "@comment"
153
+ ],
154
+ [/\/\/.*$/, "comment"]
155
+ ],
156
+ comment: [
157
+ [/[^\/*]+/, "comment"],
158
+ [
159
+ /\*\//,
160
+ "comment",
161
+ "@pop"
162
+ ],
163
+ [/[\/*]/, "comment"]
164
+ ],
165
+ jsdoc: [
166
+ [/[^\/*]+/, "comment.doc"],
167
+ [
168
+ /\*\//,
169
+ "comment.doc",
170
+ "@pop"
171
+ ],
172
+ [/[\/*]/, "comment.doc"]
173
+ ],
174
+ regexp: [
175
+ [/(\{)(\d+(?:,\d*)?)(\})/, [
176
+ "regexp.escape.control",
177
+ "regexp.escape.control",
178
+ "regexp.escape.control"
179
+ ]],
180
+ [/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/, ["regexp.escape.control", {
181
+ token: "regexp.escape.control",
182
+ next: "@regexrange"
183
+ }]],
184
+ [/(\()(\?:|\?=|\?!)/, ["regexp.escape.control", "regexp.escape.control"]],
185
+ [/[()]/, "regexp.escape.control"],
186
+ [/@regexpctl/, "regexp.escape.control"],
187
+ [/[^\\\/]/, "regexp"],
188
+ [/@regexpesc/, "regexp.escape"],
189
+ [/\\\./, "regexp.invalid"],
190
+ [/(\/)([dgimsuy]*)/, [{
191
+ token: "regexp",
192
+ bracket: "@close",
193
+ next: "@pop"
194
+ }, "keyword.other"]]
195
+ ],
196
+ regexrange: [
197
+ [/-/, "regexp.escape.control"],
198
+ [/\^/, "regexp.invalid"],
199
+ [/@regexpesc/, "regexp.escape"],
200
+ [/[^\]]/, "regexp"],
201
+ [/\]/, {
202
+ token: "regexp.escape.control",
203
+ next: "@pop",
204
+ bracket: "@close"
205
+ }]
206
+ ],
207
+ string_double: [
208
+ [/[^\\"]+/, "string"],
209
+ [/@escapes/, "string.escape"],
210
+ [/\\./, "string.escape.invalid"],
211
+ [
212
+ /"/,
213
+ "string",
214
+ "@pop"
215
+ ]
216
+ ],
217
+ string_single: [
218
+ [/[^\\']+/, "string"],
219
+ [/@escapes/, "string.escape"],
220
+ [/\\./, "string.escape.invalid"],
221
+ [
222
+ /'/,
223
+ "string",
224
+ "@pop"
225
+ ]
226
+ ],
227
+ string_backtick: [
228
+ [/\$\{/, {
229
+ token: "delimiter.bracket",
230
+ next: "@bracketCounting"
231
+ }],
232
+ [/[^\\`$]+/, "string"],
233
+ [/@escapes/, "string.escape"],
234
+ [/\\./, "string.escape.invalid"],
235
+ [
236
+ /`/,
237
+ "string",
238
+ "@pop"
239
+ ]
240
+ ],
241
+ bracketCounting: [
242
+ [
243
+ /\{/,
244
+ "delimiter.bracket",
245
+ "@bracketCounting"
246
+ ],
247
+ [
248
+ /\}/,
249
+ "delimiter.bracket",
250
+ "@pop"
251
+ ],
252
+ { include: "common" }
253
+ ]
254
+ }
255
+ }, r = t, i = {
256
+ defaultToken: "invalid",
257
+ tokenPostfix: ".js",
258
+ keywords: /* @__PURE__ */ "break.case.catch.class.continue.const.constructor.debugger.default.delete.do.else.export.extends.false.finally.for.from.function.get.if.import.in.instanceof.let.new.null.return.set.static.super.switch.symbol.this.throw.true.try.typeof.undefined.var.void.while.with.yield.async.await.of".split("."),
259
+ typeKeywords: [],
260
+ operators: n.operators,
261
+ symbols: n.symbols,
262
+ escapes: n.escapes,
263
+ digits: n.digits,
264
+ octaldigits: n.octaldigits,
265
+ binarydigits: n.binarydigits,
266
+ hexdigits: n.hexdigits,
267
+ regexpctl: n.regexpctl,
268
+ regexpesc: n.regexpesc,
269
+ tokenizer: n.tokenizer
270
+ };
271
+ //#endregion
272
+ export { r as conf, i as language };
@@ -0,0 +1,116 @@
1
+ import { h as e, n as t } from "./editor.api2-PX2PsJx9.js";
2
+ //#region node_modules/monaco-editor/esm/vs/language/typescript/monaco.contribution.js
3
+ var n = /* @__PURE__ */ ((e) => (e[e.ES3 = 0] = "ES3", e[e.ES5 = 1] = "ES5", e[e.ES2015 = 2] = "ES2015", e[e.ES2016 = 3] = "ES2016", e[e.ES2017 = 4] = "ES2017", e[e.ES2018 = 5] = "ES2018", e[e.ES2019 = 6] = "ES2019", e[e.ES2020 = 7] = "ES2020", e[e.ESNext = 99] = "ESNext", e[e.JSON = 100] = "JSON", e[e.Latest = 99] = "Latest", e))(n || {}), r = class {
4
+ constructor(e, n, r, i, a) {
5
+ this._onDidChange = new t(), this._onDidExtraLibsChange = new t(), this._extraLibs = /* @__PURE__ */ Object.create(null), this._removedExtraLibs = /* @__PURE__ */ Object.create(null), this._eagerModelSync = !1, this.setCompilerOptions(e), this.setDiagnosticsOptions(n), this.setWorkerOptions(r), this.setInlayHintsOptions(i), this.setModeConfiguration(a), this._onDidExtraLibsChangeTimeout = -1;
6
+ }
7
+ get onDidChange() {
8
+ return this._onDidChange.event;
9
+ }
10
+ get onDidExtraLibsChange() {
11
+ return this._onDidExtraLibsChange.event;
12
+ }
13
+ get modeConfiguration() {
14
+ return this._modeConfiguration;
15
+ }
16
+ get workerOptions() {
17
+ return this._workerOptions;
18
+ }
19
+ get inlayHintsOptions() {
20
+ return this._inlayHintsOptions;
21
+ }
22
+ getExtraLibs() {
23
+ return this._extraLibs;
24
+ }
25
+ addExtraLib(e, t) {
26
+ let n;
27
+ if (n = t === void 0 ? `ts:extralib-${Math.random().toString(36).substring(2, 15)}` : t, this._extraLibs[n] && this._extraLibs[n].content === e) return { dispose: () => {} };
28
+ let r = 1;
29
+ return this._removedExtraLibs[n] && (r = this._removedExtraLibs[n] + 1), this._extraLibs[n] && (r = this._extraLibs[n].version + 1), this._extraLibs[n] = {
30
+ content: e,
31
+ version: r
32
+ }, this._fireOnDidExtraLibsChangeSoon(), { dispose: () => {
33
+ let e = this._extraLibs[n];
34
+ e && e.version === r && (delete this._extraLibs[n], this._removedExtraLibs[n] = r, this._fireOnDidExtraLibsChangeSoon());
35
+ } };
36
+ }
37
+ setExtraLibs(e) {
38
+ for (let e in this._extraLibs) this._removedExtraLibs[e] = this._extraLibs[e].version;
39
+ if (this._extraLibs = /* @__PURE__ */ Object.create(null), e && e.length > 0) for (let t of e) {
40
+ let e = t.filePath || `ts:extralib-${Math.random().toString(36).substring(2, 15)}`, n = t.content, r = 1;
41
+ this._removedExtraLibs[e] && (r = this._removedExtraLibs[e] + 1), this._extraLibs[e] = {
42
+ content: n,
43
+ version: r
44
+ };
45
+ }
46
+ this._fireOnDidExtraLibsChangeSoon();
47
+ }
48
+ _fireOnDidExtraLibsChangeSoon() {
49
+ this._onDidExtraLibsChangeTimeout === -1 && (this._onDidExtraLibsChangeTimeout = window.setTimeout(() => {
50
+ this._onDidExtraLibsChangeTimeout = -1, this._onDidExtraLibsChange.fire(void 0);
51
+ }, 0));
52
+ }
53
+ getCompilerOptions() {
54
+ return this._compilerOptions;
55
+ }
56
+ setCompilerOptions(e) {
57
+ this._compilerOptions = e || /* @__PURE__ */ Object.create(null), this._onDidChange.fire(void 0);
58
+ }
59
+ getDiagnosticsOptions() {
60
+ return this._diagnosticsOptions;
61
+ }
62
+ setDiagnosticsOptions(e) {
63
+ this._diagnosticsOptions = e || /* @__PURE__ */ Object.create(null), this._onDidChange.fire(void 0);
64
+ }
65
+ setWorkerOptions(e) {
66
+ this._workerOptions = e || /* @__PURE__ */ Object.create(null), this._onDidChange.fire(void 0);
67
+ }
68
+ setInlayHintsOptions(e) {
69
+ this._inlayHintsOptions = e || /* @__PURE__ */ Object.create(null), this._onDidChange.fire(void 0);
70
+ }
71
+ setMaximumWorkerIdleTime(e) {}
72
+ setEagerModelSync(e) {
73
+ this._eagerModelSync = e;
74
+ }
75
+ getEagerModelSync() {
76
+ return this._eagerModelSync;
77
+ }
78
+ setModeConfiguration(e) {
79
+ this._modeConfiguration = e || /* @__PURE__ */ Object.create(null), this._onDidChange.fire(void 0);
80
+ }
81
+ }, i = {
82
+ completionItems: !0,
83
+ hovers: !0,
84
+ documentSymbols: !0,
85
+ definitions: !0,
86
+ references: !0,
87
+ documentHighlights: !0,
88
+ rename: !0,
89
+ diagnostics: !0,
90
+ documentRangeFormattingEdits: !0,
91
+ signatureHelp: !0,
92
+ onTypeFormattingEdits: !0,
93
+ codeActions: !0,
94
+ inlayHints: !0
95
+ }, a = new r({
96
+ allowNonTsExtensions: !0,
97
+ target: 99
98
+ }, {
99
+ noSemanticValidation: !1,
100
+ noSyntaxValidation: !1,
101
+ onlyVisible: !1
102
+ }, {}, {}, i), o = new r({
103
+ allowNonTsExtensions: !0,
104
+ allowJs: !0,
105
+ target: 99
106
+ }, {
107
+ noSemanticValidation: !0,
108
+ noSyntaxValidation: !1,
109
+ onlyVisible: !1
110
+ }, {}, {}, i);
111
+ function s() {
112
+ return import("./tsMode-J2Knw729.js");
113
+ }
114
+ e.onLanguage("typescript", () => s().then((e) => e.setupTypeScript(a))), e.onLanguage("javascript", () => s().then((e) => e.setupJavaScript(o)));
115
+ //#endregion
116
+ export { o as n, a as r, n as t };