@likec4/language-server 1.38.1 → 1.39.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/dist/LikeC4LanguageServices.d.ts +7 -0
- package/dist/LikeC4LanguageServices.js +25 -4
- package/dist/Rpc.js +9 -2
- package/dist/ast.d.ts +1 -1
- package/dist/ast.js +2 -1
- package/dist/bundled.d.ts +8 -0
- package/dist/bundled.js +40 -0
- package/dist/bundled.mjs +3629 -3523
- package/dist/filesystem/ChokidarWatcher.js +12 -9
- package/dist/filesystem/LikeC4FileSystem.d.ts +0 -2
- package/dist/filesystem/LikeC4FileSystem.js +7 -5
- package/dist/filesystem/index.d.ts +7 -0
- package/dist/filesystem/index.js +3 -0
- package/dist/generated/ast.d.ts +1 -0
- package/dist/generated/ast.js +2 -1
- package/dist/generated/grammar.js +1 -1
- package/dist/generated-lib/icons.js +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/logger.js +1 -1
- package/dist/mcp/MCPServerFactory.js +6 -5
- package/dist/mcp/server/StreamableLikeC4MCPServer.d.ts +2 -2
- package/dist/mcp/server/StreamableLikeC4MCPServer.js +97 -100
- package/dist/mcp/server/WithMCPServer.d.ts +3 -1
- package/dist/mcp/server/WithMCPServer.js +6 -5
- package/dist/mcp/tools/search-element.js +26 -11
- package/dist/mcp/utils.js +2 -2
- package/dist/model/builder/MergedSpecification.d.ts +2 -2
- package/dist/model/builder/MergedSpecification.js +4 -7
- package/dist/model/builder/assignTagColors.js +1 -1
- package/dist/model/builder/buildModel.d.ts +3 -8
- package/dist/model/builder/buildModel.js +14 -11
- package/dist/model/model-builder.d.ts +1 -1
- package/dist/model/model-locator.js +2 -1
- package/dist/model/model-parser.d.ts +19 -46
- package/dist/model/model-parser.js +13 -3
- package/dist/model/parser/Base.d.ts +4 -7
- package/dist/model/parser/Base.js +19 -0
- package/dist/model/parser/DeploymentModelParser.d.ts +2 -5
- package/dist/model/parser/DeploymentViewParser.d.ts +2 -5
- package/dist/model/parser/FqnRefParser.d.ts +2 -5
- package/dist/model/parser/GlobalsParser.d.ts +2 -5
- package/dist/model/parser/ImportsParser.d.ts +2 -5
- package/dist/model/parser/ModelParser.d.ts +2 -5
- package/dist/model/parser/PredicatesParser.d.ts +2 -5
- package/dist/model/parser/SpecificationParser.d.ts +2 -5
- package/dist/model/parser/ViewsParser.d.ts +2 -5
- package/dist/protocol.d.ts +16 -2
- package/dist/protocol.js +4 -0
- package/dist/test/testServices.d.ts +5 -1
- package/dist/test/testServices.js +18 -3
- package/dist/utils/disposable.d.ts +1 -1
- package/dist/utils/stringHash.js +1 -1
- package/dist/view-utils/resolve-relative-paths.js +1 -1
- package/dist/workspace/ProjectsManager.d.ts +24 -10
- package/dist/workspace/ProjectsManager.js +72 -27
- package/dist/workspace/WorkspaceManager.js +5 -4
- package/package.json +20 -26
- package/dist/config/index.d.ts +0 -1
- package/dist/config/index.js +0 -1
- package/dist/config/schema.d.ts +0 -10
- package/dist/config/schema.js +0 -39
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@likec4/language-server",
|
|
3
3
|
"description": "LikeC4 Language Server",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.39.1",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"bugs": "https://github.com/likec4/likec4/issues",
|
|
7
7
|
"homepage": "https://likec4.dev",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"directory": "packages/language-server"
|
|
21
21
|
},
|
|
22
22
|
"engines": {
|
|
23
|
-
"node": ">=20.19.
|
|
23
|
+
"node": ">=20.19.4"
|
|
24
24
|
},
|
|
25
25
|
"engineStrict": true,
|
|
26
26
|
"type": "module",
|
|
@@ -42,14 +42,6 @@
|
|
|
42
42
|
"default": "./dist/browser.js"
|
|
43
43
|
}
|
|
44
44
|
},
|
|
45
|
-
"./config": {
|
|
46
|
-
"sources": "./src/config/index.ts",
|
|
47
|
-
"default": {
|
|
48
|
-
"types": "./dist/config/index.d.ts",
|
|
49
|
-
"import": "./dist/config/index.js",
|
|
50
|
-
"default": "./dist/config/index.js"
|
|
51
|
-
}
|
|
52
|
-
},
|
|
53
45
|
"./likec4lib": {
|
|
54
46
|
"sources": "./src/likec4lib.ts",
|
|
55
47
|
"default": {
|
|
@@ -89,26 +81,29 @@
|
|
|
89
81
|
"access": "public"
|
|
90
82
|
},
|
|
91
83
|
"dependencies": {
|
|
92
|
-
"@hpcc-js/wasm-graphviz": "1.
|
|
84
|
+
"@hpcc-js/wasm-graphviz": "1.12.0",
|
|
85
|
+
"bundle-n-require": "^1.1.2",
|
|
86
|
+
"esbuild": "0.25.9"
|
|
93
87
|
},
|
|
94
88
|
"devDependencies": {
|
|
95
|
-
"@
|
|
96
|
-
"@
|
|
97
|
-
"@types/vscode": "^1.84.0",
|
|
98
|
-
"@modelcontextprotocol/sdk": "^1.17.2",
|
|
89
|
+
"@hono/node-server": "^1.19.1",
|
|
90
|
+
"@modelcontextprotocol/sdk": "^1.17.4",
|
|
99
91
|
"@msgpack/msgpack": "^3.1.2",
|
|
100
92
|
"@smithy/util-base64": "^4.0.0",
|
|
101
|
-
"@
|
|
102
|
-
"@types/
|
|
93
|
+
"@types/chroma-js": "^3.1.1",
|
|
94
|
+
"@types/natural-compare-lite": "^1.4.2",
|
|
95
|
+
"@types/node": "~20.19.11",
|
|
103
96
|
"@types/picomatch": "^4.0.2",
|
|
97
|
+
"@types/vscode": "^1.84.0",
|
|
104
98
|
"@types/which": "^3.0.4",
|
|
105
99
|
"chokidar": "^4.0.3",
|
|
106
100
|
"chroma-js": "^3.1.2",
|
|
107
101
|
"defu": "^6.1.4",
|
|
108
102
|
"esm-env": "^1.2.2",
|
|
109
|
-
"hono": "^4.9.0",
|
|
110
103
|
"fast-equals": "^5.2.2",
|
|
111
104
|
"fdir": "6.4.6",
|
|
105
|
+
"fetch-to-node": "^2.1.0",
|
|
106
|
+
"hono": "^4.9.6",
|
|
112
107
|
"indent-string": "^5.0.0",
|
|
113
108
|
"json5": "^2.2.3",
|
|
114
109
|
"langium": "3.5.0",
|
|
@@ -119,7 +114,6 @@
|
|
|
119
114
|
"p-timeout": "6.1.4",
|
|
120
115
|
"picomatch": "^4.0.3",
|
|
121
116
|
"pretty-ms": "^9.2.0",
|
|
122
|
-
"fetch-to-node": "^2.1.0",
|
|
123
117
|
"remeda": "^2.23.1",
|
|
124
118
|
"strip-indent": "^4.0.0",
|
|
125
119
|
"tsx": "4.20.3",
|
|
@@ -128,7 +122,6 @@
|
|
|
128
122
|
"typescript": "5.9.2",
|
|
129
123
|
"ufo": "1.6.1",
|
|
130
124
|
"unbuild": "3.5.0",
|
|
131
|
-
"valibot": "^1.1.0",
|
|
132
125
|
"vitest": "3.2.4",
|
|
133
126
|
"vscode-jsonrpc": "8.2.1",
|
|
134
127
|
"vscode-languageserver": "9.0.1",
|
|
@@ -136,12 +129,13 @@
|
|
|
136
129
|
"vscode-languageserver-types": "3.17.5",
|
|
137
130
|
"vscode-uri": "3.1.0",
|
|
138
131
|
"which": "^5.0.0",
|
|
139
|
-
"zod": "3.25.
|
|
140
|
-
"@likec4/core": "1.
|
|
141
|
-
"@likec4/
|
|
142
|
-
"@likec4/
|
|
143
|
-
"@likec4/
|
|
144
|
-
"@likec4/
|
|
132
|
+
"zod": "3.25.76",
|
|
133
|
+
"@likec4/core": "1.39.1",
|
|
134
|
+
"@likec4/config": "1.39.1",
|
|
135
|
+
"@likec4/icons": "1.39.1",
|
|
136
|
+
"@likec4/log": "1.39.1",
|
|
137
|
+
"@likec4/layouts": "1.39.1",
|
|
138
|
+
"@likec4/tsconfig": "1.39.1"
|
|
145
139
|
},
|
|
146
140
|
"scripts": {
|
|
147
141
|
"typecheck": "tsc -b --verbose",
|
package/dist/config/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { parseConfigJson, ProjectConfig, validateConfig } from './schema';
|
package/dist/config/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { parseConfigJson, ProjectConfig, validateConfig } from "./schema.js";
|
package/dist/config/schema.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import * as v from 'valibot';
|
|
2
|
-
export declare const ProjectConfig: v.ObjectSchema<{
|
|
3
|
-
readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, "Project name cannot be empty">, v.ExcludesAction<string, "default", "Project name cannot be \"default\"">, v.ExcludesAction<string, ".", "Project name cannot contain \".\", try to use A-z, 0-9, _ and -">, v.ExcludesAction<string, "@", "Project name cannot contain \"@\", try to use A-z, 0-9, _ and -">, v.ExcludesAction<string, "#", "Project name cannot contain \"#\", try to use A-z, 0-9, _ and -">, v.DescriptionAction<string, "Project name, must be unique in the workspace">]>;
|
|
4
|
-
readonly title: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, "Project title cannot be empty if specified">, v.DescriptionAction<string, "A human readable title for the project">]>, undefined>;
|
|
5
|
-
readonly contactPerson: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, "Contact person cannot be empty if specified">, v.DescriptionAction<string, "A person who has been involved in creating or maintaining this project">]>, undefined>;
|
|
6
|
-
readonly exclude: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.StringSchema<undefined>, undefined>, v.DescriptionAction<string[], "List of file patterns to exclude from the project, default is [\"**/node_modules/**\"]">]>, undefined>;
|
|
7
|
-
}, undefined>;
|
|
8
|
-
export type ProjectConfig = v.InferOutput<typeof ProjectConfig>;
|
|
9
|
-
export declare function parseConfigJson(config: string): ProjectConfig;
|
|
10
|
-
export declare function validateConfig(config: unknown): ProjectConfig;
|
package/dist/config/schema.js
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import JSON5 from "json5";
|
|
2
|
-
import * as v from "valibot";
|
|
3
|
-
export const ProjectConfig = v.object({
|
|
4
|
-
name: v.pipe(
|
|
5
|
-
v.string(),
|
|
6
|
-
v.nonEmpty("Project name cannot be empty"),
|
|
7
|
-
v.excludes("default", 'Project name cannot be "default"'),
|
|
8
|
-
v.excludes(".", 'Project name cannot contain ".", try to use A-z, 0-9, _ and -'),
|
|
9
|
-
v.excludes("@", 'Project name cannot contain "@", try to use A-z, 0-9, _ and -'),
|
|
10
|
-
v.excludes("#", 'Project name cannot contain "#", try to use A-z, 0-9, _ and -'),
|
|
11
|
-
v.description("Project name, must be unique in the workspace")
|
|
12
|
-
),
|
|
13
|
-
title: v.optional(
|
|
14
|
-
v.pipe(
|
|
15
|
-
v.string(),
|
|
16
|
-
v.nonEmpty("Project title cannot be empty if specified"),
|
|
17
|
-
v.description("A human readable title for the project")
|
|
18
|
-
)
|
|
19
|
-
),
|
|
20
|
-
contactPerson: v.optional(
|
|
21
|
-
v.pipe(
|
|
22
|
-
v.string(),
|
|
23
|
-
v.nonEmpty("Contact person cannot be empty if specified"),
|
|
24
|
-
v.description("A person who has been involved in creating or maintaining this project")
|
|
25
|
-
)
|
|
26
|
-
),
|
|
27
|
-
exclude: v.optional(
|
|
28
|
-
v.pipe(
|
|
29
|
-
v.array(v.string()),
|
|
30
|
-
v.description('List of file patterns to exclude from the project, default is ["**/node_modules/**"]')
|
|
31
|
-
)
|
|
32
|
-
)
|
|
33
|
-
});
|
|
34
|
-
export function parseConfigJson(config) {
|
|
35
|
-
return validateConfig(JSON5.parse(config));
|
|
36
|
-
}
|
|
37
|
-
export function validateConfig(config) {
|
|
38
|
-
return v.parse(ProjectConfig, config);
|
|
39
|
-
}
|