@webgal/language-service 0.0.2-alpha.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.
- package/LICENSE +373 -0
- package/build/chunk-C0xms8kb.cjs +34 -0
- package/build/index.cjs +297 -0
- package/build/index.d.cts +103 -0
- package/build/index.d.mts +103 -0
- package/build/index.mjs +293 -0
- package/build/language-configuration-BeRkRSII.mjs +214 -0
- package/build/language-configuration-D41FLA6b.cjs +232 -0
- package/build/monaco-init.cjs +83 -0
- package/build/monaco-init.d.cts +7 -0
- package/build/monaco-init.d.mts +7 -0
- package/build/monaco-init.mjs +78 -0
- package/build/monaco.cjs +138 -0
- package/build/monaco.d.cts +32 -0
- package/build/monaco.d.mts +32 -0
- package/build/monaco.mjs +134 -0
- package/build/node.cjs +374 -0
- package/build/node.d.cts +11 -0
- package/build/node.d.mts +11 -0
- package/build/node.mjs +370 -0
- package/build/syntaxes.cjs +12 -0
- package/build/syntaxes.d.cts +293 -0
- package/build/syntaxes.d.mts +293 -0
- package/build/syntaxes.mjs +9 -0
- package/build/themes.cjs +10 -0
- package/build/themes.d.cts +286 -0
- package/build/themes.d.mts +286 -0
- package/build/themes.mjs +8 -0
- package/build/white-Be4QIaif.cjs +1007 -0
- package/build/white-CaNrG0B0.mjs +995 -0
- package/package.json +71 -0
package/build/node.mjs
ADDED
|
@@ -0,0 +1,370 @@
|
|
|
1
|
+
import fs from "fs/promises";
|
|
2
|
+
import path from "path";
|
|
3
|
+
|
|
4
|
+
//#region src/node.ts
|
|
5
|
+
const listDirectory = async (dirPath) => {
|
|
6
|
+
try {
|
|
7
|
+
return (await fs.readdir(dirPath, { withFileTypes: true })).map((entry) => ({
|
|
8
|
+
name: entry.name,
|
|
9
|
+
isDirectory: entry.isDirectory()
|
|
10
|
+
}));
|
|
11
|
+
} catch {
|
|
12
|
+
return null;
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
const findFileInDirectory = async (dirPath, targetName, ignoreDirs) => {
|
|
16
|
+
const entries = await fs.readdir(dirPath, { withFileTypes: true });
|
|
17
|
+
for (const entry of entries) {
|
|
18
|
+
if (entry.isFile() && entry.name === targetName) return path.join(dirPath, entry.name);
|
|
19
|
+
if (entry.isDirectory() && !ignoreDirs.has(entry.name)) {
|
|
20
|
+
const result = await findFileInDirectory(path.join(dirPath, entry.name), targetName, ignoreDirs);
|
|
21
|
+
if (result) return result;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
return null;
|
|
25
|
+
};
|
|
26
|
+
function createNodeFileSystem(options) {
|
|
27
|
+
const root = path.resolve(options.root);
|
|
28
|
+
const ignoreDirs = new Set(options.ignoreDirs ?? ["node_modules", ".git"]);
|
|
29
|
+
const sceneDir = options.sceneDir ?? "scene";
|
|
30
|
+
let rootEntry = {
|
|
31
|
+
type: "dir",
|
|
32
|
+
children: {}
|
|
33
|
+
};
|
|
34
|
+
const loadedDirectories = /* @__PURE__ */ new Set();
|
|
35
|
+
const loadedFiles = /* @__PURE__ */ new Set();
|
|
36
|
+
const listeners = /* @__PURE__ */ new Set();
|
|
37
|
+
const emit = (changes) => {
|
|
38
|
+
for (const listener of listeners) listener(changes);
|
|
39
|
+
};
|
|
40
|
+
const isWithinRoot = (targetPath) => {
|
|
41
|
+
const absolute = path.resolve(targetPath);
|
|
42
|
+
const rel = path.relative(root, absolute);
|
|
43
|
+
if (rel === "" || rel === ".") return true;
|
|
44
|
+
return !rel.startsWith("..") && !path.isAbsolute(rel);
|
|
45
|
+
};
|
|
46
|
+
const toSegments = (targetPath) => {
|
|
47
|
+
const absolute = path.resolve(targetPath);
|
|
48
|
+
const rel = path.relative(root, absolute);
|
|
49
|
+
if (rel === "" || rel === ".") return [];
|
|
50
|
+
if (rel.startsWith("..") || path.isAbsolute(rel)) return null;
|
|
51
|
+
return rel.split(path.sep).filter((s) => s.length > 0);
|
|
52
|
+
};
|
|
53
|
+
const getEntryBySegments = (segments) => {
|
|
54
|
+
let current = rootEntry;
|
|
55
|
+
for (const segment of segments) {
|
|
56
|
+
if (current.type !== "dir") return null;
|
|
57
|
+
const next = current.children[segment];
|
|
58
|
+
if (!next) return null;
|
|
59
|
+
current = next;
|
|
60
|
+
}
|
|
61
|
+
return current;
|
|
62
|
+
};
|
|
63
|
+
const ensureDirectoryBySegments = (segments) => {
|
|
64
|
+
let current = rootEntry;
|
|
65
|
+
for (const segment of segments) {
|
|
66
|
+
if (current.type !== "dir") throw new Error("Path segment is not a directory");
|
|
67
|
+
const dir = current;
|
|
68
|
+
const existing = dir.children[segment];
|
|
69
|
+
if (!existing) {
|
|
70
|
+
const created = {
|
|
71
|
+
type: "dir",
|
|
72
|
+
children: {}
|
|
73
|
+
};
|
|
74
|
+
dir.children[segment] = created;
|
|
75
|
+
current = created;
|
|
76
|
+
continue;
|
|
77
|
+
}
|
|
78
|
+
if (existing.type !== "dir") throw new Error("Path segment is not a directory");
|
|
79
|
+
current = existing;
|
|
80
|
+
}
|
|
81
|
+
if (current.type !== "dir") throw new Error("Path is not a directory");
|
|
82
|
+
return current;
|
|
83
|
+
};
|
|
84
|
+
const ensureDirectoryLoaded = async (dirPath) => {
|
|
85
|
+
const absolute = path.resolve(dirPath);
|
|
86
|
+
if (!isWithinRoot(absolute)) return;
|
|
87
|
+
if (loadedDirectories.has(absolute)) return;
|
|
88
|
+
const segments = toSegments(absolute);
|
|
89
|
+
if (!segments) return;
|
|
90
|
+
const dirEntry = ensureDirectoryBySegments(segments);
|
|
91
|
+
const entries = await listDirectory(absolute);
|
|
92
|
+
if (!entries) {
|
|
93
|
+
loadedDirectories.add(absolute);
|
|
94
|
+
return;
|
|
95
|
+
}
|
|
96
|
+
for (const entry of entries) if (entry.isDirectory) dirEntry.children[entry.name] ??= {
|
|
97
|
+
type: "dir",
|
|
98
|
+
children: {}
|
|
99
|
+
};
|
|
100
|
+
else dirEntry.children[entry.name] ??= {
|
|
101
|
+
type: "file",
|
|
102
|
+
content: ""
|
|
103
|
+
};
|
|
104
|
+
loadedDirectories.add(absolute);
|
|
105
|
+
};
|
|
106
|
+
const getTree = () => rootEntry;
|
|
107
|
+
const setTree = (tree) => {
|
|
108
|
+
rootEntry = tree.type === "dir" ? tree : {
|
|
109
|
+
type: "dir",
|
|
110
|
+
children: {}
|
|
111
|
+
};
|
|
112
|
+
loadedDirectories.clear();
|
|
113
|
+
loadedFiles.clear();
|
|
114
|
+
emit([{
|
|
115
|
+
type: "setTree",
|
|
116
|
+
tree: rootEntry
|
|
117
|
+
}]);
|
|
118
|
+
};
|
|
119
|
+
const writeFile = async (targetPath, content) => {
|
|
120
|
+
const absolute = path.resolve(targetPath);
|
|
121
|
+
if (!isWithinRoot(absolute)) return;
|
|
122
|
+
const segments = toSegments(absolute);
|
|
123
|
+
if (!segments || segments.length === 0) return;
|
|
124
|
+
const fileName = segments[segments.length - 1];
|
|
125
|
+
const parent = ensureDirectoryBySegments(segments.slice(0, -1));
|
|
126
|
+
parent.children[fileName] = {
|
|
127
|
+
type: "file",
|
|
128
|
+
content
|
|
129
|
+
};
|
|
130
|
+
loadedFiles.add(absolute);
|
|
131
|
+
emit([{
|
|
132
|
+
type: "writeFile",
|
|
133
|
+
path: absolute,
|
|
134
|
+
content
|
|
135
|
+
}]);
|
|
136
|
+
};
|
|
137
|
+
const mkdir = async (targetPath) => {
|
|
138
|
+
const absolute = path.resolve(targetPath);
|
|
139
|
+
if (!isWithinRoot(absolute)) return;
|
|
140
|
+
const segments = toSegments(absolute);
|
|
141
|
+
if (!segments) return;
|
|
142
|
+
ensureDirectoryBySegments(segments);
|
|
143
|
+
emit([{
|
|
144
|
+
type: "mkdir",
|
|
145
|
+
path: absolute
|
|
146
|
+
}]);
|
|
147
|
+
};
|
|
148
|
+
const deletePath = async (targetPath) => {
|
|
149
|
+
const absolute = path.resolve(targetPath);
|
|
150
|
+
if (!isWithinRoot(absolute)) return;
|
|
151
|
+
const segments = toSegments(absolute);
|
|
152
|
+
if (!segments || segments.length === 0) return;
|
|
153
|
+
const name = segments[segments.length - 1];
|
|
154
|
+
const parentSegments = segments.slice(0, -1);
|
|
155
|
+
const parentEntry = parentSegments.length === 0 ? rootEntry : getEntryBySegments(parentSegments);
|
|
156
|
+
if (!parentEntry || parentEntry.type !== "dir") return;
|
|
157
|
+
delete parentEntry.children[name];
|
|
158
|
+
loadedFiles.delete(absolute);
|
|
159
|
+
loadedDirectories.delete(absolute);
|
|
160
|
+
emit([{
|
|
161
|
+
type: "deletePath",
|
|
162
|
+
path: absolute
|
|
163
|
+
}]);
|
|
164
|
+
};
|
|
165
|
+
const rename = async (from, to) => {
|
|
166
|
+
const fromAbs = path.resolve(from);
|
|
167
|
+
const toAbs = path.resolve(to);
|
|
168
|
+
if (!isWithinRoot(fromAbs) || !isWithinRoot(toAbs)) return;
|
|
169
|
+
const fromSegments = toSegments(fromAbs);
|
|
170
|
+
if (!fromSegments || fromSegments.length === 0) return;
|
|
171
|
+
const fromName = fromSegments[fromSegments.length - 1];
|
|
172
|
+
const fromParentSegments = fromSegments.slice(0, -1);
|
|
173
|
+
const fromParentEntry = fromParentSegments.length === 0 ? rootEntry : getEntryBySegments(fromParentSegments);
|
|
174
|
+
if (!fromParentEntry || fromParentEntry.type !== "dir") return;
|
|
175
|
+
const entry = fromParentEntry.children[fromName];
|
|
176
|
+
if (!entry) return;
|
|
177
|
+
delete fromParentEntry.children[fromName];
|
|
178
|
+
const toPathSegments = toSegments(toAbs);
|
|
179
|
+
if (!toPathSegments || toPathSegments.length === 0) return;
|
|
180
|
+
const toName = toPathSegments[toPathSegments.length - 1];
|
|
181
|
+
const toParent = ensureDirectoryBySegments(toPathSegments.slice(0, -1));
|
|
182
|
+
toParent.children[toName] = entry;
|
|
183
|
+
if (loadedFiles.has(fromAbs)) {
|
|
184
|
+
loadedFiles.delete(fromAbs);
|
|
185
|
+
loadedFiles.add(toAbs);
|
|
186
|
+
}
|
|
187
|
+
if (loadedDirectories.has(fromAbs)) {
|
|
188
|
+
loadedDirectories.delete(fromAbs);
|
|
189
|
+
loadedDirectories.add(toAbs);
|
|
190
|
+
}
|
|
191
|
+
emit([{
|
|
192
|
+
type: "rename",
|
|
193
|
+
from: fromAbs,
|
|
194
|
+
to: toAbs
|
|
195
|
+
}]);
|
|
196
|
+
};
|
|
197
|
+
const applyChanges = async (changes) => {
|
|
198
|
+
for (const change of changes) {
|
|
199
|
+
if (change.type === "writeFile") {
|
|
200
|
+
await writeFile(change.path, change.content);
|
|
201
|
+
continue;
|
|
202
|
+
}
|
|
203
|
+
if (change.type === "mkdir") {
|
|
204
|
+
await mkdir(change.path);
|
|
205
|
+
continue;
|
|
206
|
+
}
|
|
207
|
+
if (change.type === "deletePath") {
|
|
208
|
+
await deletePath(change.path);
|
|
209
|
+
continue;
|
|
210
|
+
}
|
|
211
|
+
if (change.type === "rename") {
|
|
212
|
+
await rename(change.from, change.to);
|
|
213
|
+
continue;
|
|
214
|
+
}
|
|
215
|
+
if (change.type === "setTree") setTree(change.tree);
|
|
216
|
+
}
|
|
217
|
+
};
|
|
218
|
+
const onDidChange = (listener) => {
|
|
219
|
+
listeners.add(listener);
|
|
220
|
+
return () => {
|
|
221
|
+
listeners.delete(listener);
|
|
222
|
+
};
|
|
223
|
+
};
|
|
224
|
+
const stat = async (targetPath) => {
|
|
225
|
+
const absolute = path.resolve(targetPath);
|
|
226
|
+
if (isWithinRoot(absolute)) {
|
|
227
|
+
const segments = toSegments(absolute);
|
|
228
|
+
if (segments) {
|
|
229
|
+
const existing = getEntryBySegments(segments);
|
|
230
|
+
if (existing) return {
|
|
231
|
+
isFile: existing.type === "file",
|
|
232
|
+
isDirectory: existing.type === "dir"
|
|
233
|
+
};
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
try {
|
|
237
|
+
const stats = await fs.stat(absolute);
|
|
238
|
+
if (isWithinRoot(absolute)) {
|
|
239
|
+
const segments = toSegments(absolute);
|
|
240
|
+
if (segments) {
|
|
241
|
+
if (stats.isDirectory()) ensureDirectoryBySegments(segments);
|
|
242
|
+
else if (segments.length > 0) {
|
|
243
|
+
const name = segments[segments.length - 1];
|
|
244
|
+
const parent = ensureDirectoryBySegments(segments.slice(0, -1));
|
|
245
|
+
parent.children[name] ??= {
|
|
246
|
+
type: "file",
|
|
247
|
+
content: ""
|
|
248
|
+
};
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
return {
|
|
253
|
+
isFile: stats.isFile(),
|
|
254
|
+
isDirectory: stats.isDirectory()
|
|
255
|
+
};
|
|
256
|
+
} catch {
|
|
257
|
+
return null;
|
|
258
|
+
}
|
|
259
|
+
};
|
|
260
|
+
const readDirectory = async (targetPath) => {
|
|
261
|
+
const absolute = path.resolve(targetPath);
|
|
262
|
+
if (isWithinRoot(absolute)) {
|
|
263
|
+
await ensureDirectoryLoaded(absolute);
|
|
264
|
+
const segments = toSegments(absolute);
|
|
265
|
+
if (!segments) return null;
|
|
266
|
+
const entry = getEntryBySegments(segments);
|
|
267
|
+
if (!entry || entry.type !== "dir") return null;
|
|
268
|
+
return Object.entries(entry.children).map(([name, child]) => ({
|
|
269
|
+
name,
|
|
270
|
+
isDirectory: child.type === "dir"
|
|
271
|
+
}));
|
|
272
|
+
}
|
|
273
|
+
return listDirectory(absolute);
|
|
274
|
+
};
|
|
275
|
+
const readFile = async (targetPath) => {
|
|
276
|
+
const absolute = path.resolve(targetPath);
|
|
277
|
+
if (isWithinRoot(absolute)) {
|
|
278
|
+
const segments = toSegments(absolute);
|
|
279
|
+
if (segments) {
|
|
280
|
+
const existing = getEntryBySegments(segments);
|
|
281
|
+
if (existing && existing.type === "file") {
|
|
282
|
+
if (loadedFiles.has(absolute)) return existing.content;
|
|
283
|
+
try {
|
|
284
|
+
const content = await fs.readFile(absolute, "utf-8");
|
|
285
|
+
existing.content = content;
|
|
286
|
+
loadedFiles.add(absolute);
|
|
287
|
+
return content;
|
|
288
|
+
} catch {
|
|
289
|
+
return null;
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
}
|
|
293
|
+
try {
|
|
294
|
+
const content = await fs.readFile(absolute, "utf-8");
|
|
295
|
+
await writeFile(absolute, content);
|
|
296
|
+
return content;
|
|
297
|
+
} catch {
|
|
298
|
+
return null;
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
try {
|
|
302
|
+
return await fs.readFile(absolute, "utf-8");
|
|
303
|
+
} catch {
|
|
304
|
+
return null;
|
|
305
|
+
}
|
|
306
|
+
};
|
|
307
|
+
const findFile = async (startPath, targetName) => {
|
|
308
|
+
const absoluteStart = path.resolve(startPath);
|
|
309
|
+
try {
|
|
310
|
+
const found = await findFileInDirectory(absoluteStart, targetName, ignoreDirs);
|
|
311
|
+
if (found && isWithinRoot(found)) {
|
|
312
|
+
const foundSegments = toSegments(found);
|
|
313
|
+
if (foundSegments && foundSegments.length > 0) {
|
|
314
|
+
const name = foundSegments[foundSegments.length - 1];
|
|
315
|
+
const parent = ensureDirectoryBySegments(foundSegments.slice(0, -1));
|
|
316
|
+
parent.children[name] ??= {
|
|
317
|
+
type: "file",
|
|
318
|
+
content: ""
|
|
319
|
+
};
|
|
320
|
+
}
|
|
321
|
+
}
|
|
322
|
+
return found;
|
|
323
|
+
} catch {
|
|
324
|
+
return null;
|
|
325
|
+
}
|
|
326
|
+
};
|
|
327
|
+
const getResourceDirectory = async (urls) => {
|
|
328
|
+
return readDirectory(path.join(root, ...urls));
|
|
329
|
+
};
|
|
330
|
+
const getAllTextWithScene = async () => {
|
|
331
|
+
const target = path.join(root, sceneDir);
|
|
332
|
+
const entries = await readDirectory(target);
|
|
333
|
+
if (!entries) return null;
|
|
334
|
+
const result = {};
|
|
335
|
+
for (const entry of entries) if (!entry.isDirectory && entry.name.endsWith(".txt")) {
|
|
336
|
+
const fullPath = path.join(target, entry.name);
|
|
337
|
+
const text = await readFile(fullPath);
|
|
338
|
+
if (text === null) continue;
|
|
339
|
+
result[entry.name] = {
|
|
340
|
+
path: fullPath,
|
|
341
|
+
name: entry.name,
|
|
342
|
+
text,
|
|
343
|
+
fullPath
|
|
344
|
+
};
|
|
345
|
+
}
|
|
346
|
+
return result;
|
|
347
|
+
};
|
|
348
|
+
return {
|
|
349
|
+
root,
|
|
350
|
+
currentDirectory: () => root,
|
|
351
|
+
join: (...parts) => path.join(...parts),
|
|
352
|
+
stat,
|
|
353
|
+
readDirectory,
|
|
354
|
+
readFile,
|
|
355
|
+
findFile,
|
|
356
|
+
getResourceDirectory,
|
|
357
|
+
getAllTextWithScene,
|
|
358
|
+
getTree,
|
|
359
|
+
setTree,
|
|
360
|
+
writeFile,
|
|
361
|
+
deletePath,
|
|
362
|
+
mkdir,
|
|
363
|
+
rename,
|
|
364
|
+
applyChanges,
|
|
365
|
+
onDidChange
|
|
366
|
+
};
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
//#endregion
|
|
370
|
+
export { createNodeFileSystem };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
|
+
const require_language_configuration = require('./language-configuration-D41FLA6b.cjs');
|
|
3
|
+
|
|
4
|
+
//#region src/syntaxes.ts
|
|
5
|
+
const webgalGrammar = require_language_configuration.webgal_tmLanguage_default;
|
|
6
|
+
const webgalConfigGrammar = require_language_configuration.webgal_config_tmLanguage_default;
|
|
7
|
+
const webgalLanguageConfiguration = require_language_configuration.language_configuration_default;
|
|
8
|
+
|
|
9
|
+
//#endregion
|
|
10
|
+
exports.webgalConfigGrammar = webgalConfigGrammar;
|
|
11
|
+
exports.webgalGrammar = webgalGrammar;
|
|
12
|
+
exports.webgalLanguageConfiguration = webgalLanguageConfiguration;
|
|
@@ -0,0 +1,293 @@
|
|
|
1
|
+
//#region src/syntaxes.d.ts
|
|
2
|
+
declare const webgalGrammar: {
|
|
3
|
+
$schema: string;
|
|
4
|
+
name: string;
|
|
5
|
+
patterns: {
|
|
6
|
+
include: string;
|
|
7
|
+
}[];
|
|
8
|
+
repository: {
|
|
9
|
+
"argument-list": {
|
|
10
|
+
patterns: ({
|
|
11
|
+
comment: string;
|
|
12
|
+
match: string;
|
|
13
|
+
captures: {
|
|
14
|
+
"1": {
|
|
15
|
+
patterns: {
|
|
16
|
+
include: string;
|
|
17
|
+
}[];
|
|
18
|
+
};
|
|
19
|
+
"2": {
|
|
20
|
+
patterns: {
|
|
21
|
+
include: string;
|
|
22
|
+
}[];
|
|
23
|
+
};
|
|
24
|
+
"3": {
|
|
25
|
+
patterns: {
|
|
26
|
+
include: string;
|
|
27
|
+
}[];
|
|
28
|
+
};
|
|
29
|
+
};
|
|
30
|
+
} | {
|
|
31
|
+
comment: string;
|
|
32
|
+
match: string;
|
|
33
|
+
captures: {
|
|
34
|
+
"1": {
|
|
35
|
+
patterns: {
|
|
36
|
+
include: string;
|
|
37
|
+
}[];
|
|
38
|
+
};
|
|
39
|
+
"2": {
|
|
40
|
+
patterns: {
|
|
41
|
+
include: string;
|
|
42
|
+
}[];
|
|
43
|
+
};
|
|
44
|
+
"3"?: undefined;
|
|
45
|
+
};
|
|
46
|
+
})[];
|
|
47
|
+
};
|
|
48
|
+
character: {
|
|
49
|
+
match: string;
|
|
50
|
+
name: string;
|
|
51
|
+
};
|
|
52
|
+
command: {
|
|
53
|
+
match: string;
|
|
54
|
+
name: string;
|
|
55
|
+
};
|
|
56
|
+
"comment-line": {
|
|
57
|
+
match: string;
|
|
58
|
+
name: string;
|
|
59
|
+
};
|
|
60
|
+
operator: {
|
|
61
|
+
match: string;
|
|
62
|
+
name: string;
|
|
63
|
+
};
|
|
64
|
+
parameter: {
|
|
65
|
+
patterns: ({
|
|
66
|
+
comment: string;
|
|
67
|
+
match: string;
|
|
68
|
+
name: string;
|
|
69
|
+
captures?: undefined;
|
|
70
|
+
} | {
|
|
71
|
+
comment: string;
|
|
72
|
+
match: string;
|
|
73
|
+
captures: {
|
|
74
|
+
"1": {
|
|
75
|
+
name: string;
|
|
76
|
+
};
|
|
77
|
+
"2": {
|
|
78
|
+
patterns: {
|
|
79
|
+
include: string;
|
|
80
|
+
}[];
|
|
81
|
+
};
|
|
82
|
+
"3": {
|
|
83
|
+
name: string;
|
|
84
|
+
};
|
|
85
|
+
};
|
|
86
|
+
name?: undefined;
|
|
87
|
+
})[];
|
|
88
|
+
};
|
|
89
|
+
utterance: {
|
|
90
|
+
patterns: ({
|
|
91
|
+
comment: string;
|
|
92
|
+
match: string;
|
|
93
|
+
captures: {
|
|
94
|
+
"0": {
|
|
95
|
+
name: string;
|
|
96
|
+
};
|
|
97
|
+
"1"?: undefined;
|
|
98
|
+
"2"?: undefined;
|
|
99
|
+
};
|
|
100
|
+
} | {
|
|
101
|
+
comment: string;
|
|
102
|
+
match: string;
|
|
103
|
+
captures: {
|
|
104
|
+
"1": {
|
|
105
|
+
name: string;
|
|
106
|
+
};
|
|
107
|
+
"2": {
|
|
108
|
+
patterns: {
|
|
109
|
+
include: string;
|
|
110
|
+
}[];
|
|
111
|
+
};
|
|
112
|
+
"0"?: undefined;
|
|
113
|
+
};
|
|
114
|
+
})[];
|
|
115
|
+
};
|
|
116
|
+
"character-colon": {
|
|
117
|
+
comment: string;
|
|
118
|
+
match: string;
|
|
119
|
+
captures: {
|
|
120
|
+
"1": {
|
|
121
|
+
name: string;
|
|
122
|
+
patterns: {
|
|
123
|
+
include: string;
|
|
124
|
+
}[];
|
|
125
|
+
};
|
|
126
|
+
"2": {
|
|
127
|
+
patterns: {
|
|
128
|
+
include: string;
|
|
129
|
+
}[];
|
|
130
|
+
};
|
|
131
|
+
"3": {
|
|
132
|
+
patterns: {
|
|
133
|
+
include: string;
|
|
134
|
+
}[];
|
|
135
|
+
};
|
|
136
|
+
"4": {
|
|
137
|
+
patterns: {
|
|
138
|
+
include: string;
|
|
139
|
+
}[];
|
|
140
|
+
};
|
|
141
|
+
};
|
|
142
|
+
};
|
|
143
|
+
"command-colon": {
|
|
144
|
+
comment: string;
|
|
145
|
+
match: string;
|
|
146
|
+
captures: {
|
|
147
|
+
"1": {
|
|
148
|
+
name: string;
|
|
149
|
+
patterns: {
|
|
150
|
+
include: string;
|
|
151
|
+
}[];
|
|
152
|
+
};
|
|
153
|
+
"2": {
|
|
154
|
+
patterns: {
|
|
155
|
+
include: string;
|
|
156
|
+
}[];
|
|
157
|
+
};
|
|
158
|
+
"3": {
|
|
159
|
+
patterns: {
|
|
160
|
+
include: string;
|
|
161
|
+
}[];
|
|
162
|
+
};
|
|
163
|
+
"4": {
|
|
164
|
+
patterns: {
|
|
165
|
+
include: string;
|
|
166
|
+
}[];
|
|
167
|
+
};
|
|
168
|
+
};
|
|
169
|
+
};
|
|
170
|
+
"command-semicolon": {
|
|
171
|
+
comment: string;
|
|
172
|
+
match: string;
|
|
173
|
+
captures: {
|
|
174
|
+
"1": {
|
|
175
|
+
name: string;
|
|
176
|
+
patterns: {
|
|
177
|
+
include: string;
|
|
178
|
+
}[];
|
|
179
|
+
};
|
|
180
|
+
"2": {
|
|
181
|
+
patterns: {
|
|
182
|
+
include: string;
|
|
183
|
+
}[];
|
|
184
|
+
};
|
|
185
|
+
};
|
|
186
|
+
};
|
|
187
|
+
"utterance-semicolon": {
|
|
188
|
+
comment: string;
|
|
189
|
+
match: string;
|
|
190
|
+
captures: {
|
|
191
|
+
"1": {
|
|
192
|
+
patterns: {
|
|
193
|
+
include: string;
|
|
194
|
+
}[];
|
|
195
|
+
};
|
|
196
|
+
"2": {
|
|
197
|
+
patterns: {
|
|
198
|
+
include: string;
|
|
199
|
+
}[];
|
|
200
|
+
};
|
|
201
|
+
};
|
|
202
|
+
};
|
|
203
|
+
statement: {
|
|
204
|
+
patterns: {
|
|
205
|
+
include: string;
|
|
206
|
+
}[];
|
|
207
|
+
};
|
|
208
|
+
};
|
|
209
|
+
scopeName: string;
|
|
210
|
+
};
|
|
211
|
+
declare const webgalConfigGrammar: {
|
|
212
|
+
$schema: string;
|
|
213
|
+
name: string;
|
|
214
|
+
patterns: {
|
|
215
|
+
include: string;
|
|
216
|
+
}[];
|
|
217
|
+
repository: {
|
|
218
|
+
command: {
|
|
219
|
+
match: string;
|
|
220
|
+
name: string;
|
|
221
|
+
};
|
|
222
|
+
"comment-line": {
|
|
223
|
+
match: string;
|
|
224
|
+
name: string;
|
|
225
|
+
};
|
|
226
|
+
operator: {
|
|
227
|
+
match: string;
|
|
228
|
+
name: string;
|
|
229
|
+
};
|
|
230
|
+
parameter: {
|
|
231
|
+
match: string;
|
|
232
|
+
name: string;
|
|
233
|
+
};
|
|
234
|
+
"command-colon": {
|
|
235
|
+
comment: string;
|
|
236
|
+
match: string;
|
|
237
|
+
captures: {
|
|
238
|
+
"1": {
|
|
239
|
+
patterns: {
|
|
240
|
+
include: string;
|
|
241
|
+
}[];
|
|
242
|
+
};
|
|
243
|
+
"2": {
|
|
244
|
+
patterns: {
|
|
245
|
+
include: string;
|
|
246
|
+
}[];
|
|
247
|
+
};
|
|
248
|
+
"3": {
|
|
249
|
+
patterns: {
|
|
250
|
+
include: string;
|
|
251
|
+
}[];
|
|
252
|
+
};
|
|
253
|
+
"4": {
|
|
254
|
+
patterns: {
|
|
255
|
+
include: string;
|
|
256
|
+
}[];
|
|
257
|
+
};
|
|
258
|
+
};
|
|
259
|
+
};
|
|
260
|
+
statement: {
|
|
261
|
+
patterns: {
|
|
262
|
+
include: string;
|
|
263
|
+
}[];
|
|
264
|
+
};
|
|
265
|
+
};
|
|
266
|
+
scopeName: string;
|
|
267
|
+
};
|
|
268
|
+
declare const webgalLanguageConfiguration: {
|
|
269
|
+
comments: {
|
|
270
|
+
lineComment: {
|
|
271
|
+
comment: string;
|
|
272
|
+
};
|
|
273
|
+
};
|
|
274
|
+
autoClosingPairs: ({
|
|
275
|
+
open: string;
|
|
276
|
+
close: string;
|
|
277
|
+
notIn?: undefined;
|
|
278
|
+
} | {
|
|
279
|
+
open: string;
|
|
280
|
+
close: string;
|
|
281
|
+
notIn: string[];
|
|
282
|
+
})[];
|
|
283
|
+
folding: {
|
|
284
|
+
markers: {
|
|
285
|
+
start: string;
|
|
286
|
+
end: string;
|
|
287
|
+
};
|
|
288
|
+
};
|
|
289
|
+
surroundingPairs: string[][];
|
|
290
|
+
wordPattern: string;
|
|
291
|
+
};
|
|
292
|
+
//#endregion
|
|
293
|
+
export { webgalConfigGrammar, webgalGrammar, webgalLanguageConfiguration };
|