likec4 1.37.0 → 1.38.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/README.md +25 -1
- package/__app__/src/main.js +161 -197
- package/__app__/src/style.css +1 -1
- package/dist/cli/index.mjs +709 -690
- package/dist/index.d.mts +26 -10
- package/dist/index.mjs +2 -2
- package/dist/shared/{likec4.cqC6tNHO.d.mts → likec4.CRYZWScz.d.mts} +674 -530
- package/dist/shared/likec4.D6zjV21i.mjs +257 -0
- package/dist/shared/likec4.enfOs0BB.mjs +4204 -0
- package/dist/vite-plugin/index.d.mts +2 -2
- package/dist/vite-plugin/index.mjs +2 -2
- package/package.json +17 -17
- package/react/index.d.mts +2 -1
- package/react/index.mjs +39 -35
- package/dist/shared/likec4.B6V1NOky.mjs +0 -258
- package/dist/shared/likec4.BKp9_9LQ.mjs +0 -2268
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { LikeC4Model } from '@likec4/core/model';
|
|
2
2
|
import { UnknownLayouted } from './model/index.mjs';
|
|
3
|
-
import { W as WorkspaceFolder, a as LikeC4Services, L as LikeC4LanguageServices, b as LikeC4Views, R as Range } from './shared/likec4.
|
|
3
|
+
import { W as WorkspaceFolder, a as LikeC4Services, L as LikeC4LanguageServices, b as LikeC4Views, R as Range } from './shared/likec4.CRYZWScz.mjs';
|
|
4
4
|
import { ProjectId, NonEmptyArray } from '@likec4/core';
|
|
5
5
|
import { DiagramView } from '@likec4/core/types';
|
|
6
6
|
export * from '@likec4/core/types';
|
|
@@ -19,7 +19,6 @@ declare class CliWorkspace {
|
|
|
19
19
|
private isInitialized;
|
|
20
20
|
constructor(services: CliServices);
|
|
21
21
|
initWorkspace(workspace: WorkspaceFolder): Promise<void>;
|
|
22
|
-
init(): Promise<void>;
|
|
23
22
|
}
|
|
24
23
|
|
|
25
24
|
type CliAddedServices = {
|
|
@@ -35,6 +34,11 @@ type CreateLanguageServiceOptions = {
|
|
|
35
34
|
* @default true
|
|
36
35
|
*/
|
|
37
36
|
useFileSystem?: boolean;
|
|
37
|
+
/**
|
|
38
|
+
* Whether to watch for changes in the workspace.
|
|
39
|
+
* @default true if useFileSystem is true, false otherwise
|
|
40
|
+
*/
|
|
41
|
+
watch?: boolean;
|
|
38
42
|
/**
|
|
39
43
|
* Logger to use for the language service.
|
|
40
44
|
* @default 'default'
|
|
@@ -45,6 +49,13 @@ type CreateLanguageServiceOptions = {
|
|
|
45
49
|
* @default 'wasm'
|
|
46
50
|
*/
|
|
47
51
|
graphviz?: 'wasm' | 'binary';
|
|
52
|
+
/**
|
|
53
|
+
* Whether to start MCP server
|
|
54
|
+
* @default false
|
|
55
|
+
*/
|
|
56
|
+
mcp?: false | 'stdio' | {
|
|
57
|
+
port: number;
|
|
58
|
+
};
|
|
48
59
|
};
|
|
49
60
|
declare function createLanguageServices(opts?: CreateLanguageServiceOptions): CliServices;
|
|
50
61
|
|
|
@@ -74,6 +85,18 @@ type LikeC4Options = {
|
|
|
74
85
|
* @default 'wasm'
|
|
75
86
|
*/
|
|
76
87
|
graphviz?: 'wasm' | 'binary';
|
|
88
|
+
/**
|
|
89
|
+
* Whether to start MCP server
|
|
90
|
+
* @default false
|
|
91
|
+
*/
|
|
92
|
+
mcp?: false | 'stdio' | {
|
|
93
|
+
port: number;
|
|
94
|
+
};
|
|
95
|
+
/**
|
|
96
|
+
* Whether to watch for changes in the workspace.
|
|
97
|
+
* @default false
|
|
98
|
+
*/
|
|
99
|
+
watch?: boolean;
|
|
77
100
|
};
|
|
78
101
|
declare class LikeC4 {
|
|
79
102
|
readonly workspace: string;
|
|
@@ -123,18 +146,11 @@ declare class LikeC4 {
|
|
|
123
146
|
* @returns true if there are errors
|
|
124
147
|
*/
|
|
125
148
|
printErrors(): boolean;
|
|
126
|
-
/**
|
|
127
|
-
* TODO Replace with watcher
|
|
128
|
-
*/
|
|
129
|
-
notifyUpdate({ changed, removed }: {
|
|
130
|
-
changed?: string;
|
|
131
|
-
removed?: string;
|
|
132
|
-
}): Promise<boolean>;
|
|
133
149
|
/**
|
|
134
150
|
* @returns a function to dispose the listener
|
|
135
151
|
*/
|
|
136
152
|
onModelUpdate(listener: () => void): () => void;
|
|
137
|
-
dispose(): void
|
|
153
|
+
dispose(): Promise<void>;
|
|
138
154
|
}
|
|
139
155
|
|
|
140
156
|
/**
|
package/dist/index.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{LikeC4Model as o}from"@likec4/core/model";export{L as LikeC4}from"./shared/likec4.
|
|
2
|
-
import"node:
|
|
1
|
+
import{LikeC4Model as o}from"@likec4/core/model";export{L as LikeC4}from"./shared/likec4.enfOs0BB.mjs";import"node:fs";import"node:path";import"node:url";import"./shared/likec4.BeWJWU7_.mjs";import"tty";import"node:util";import"util";import"path";import"os";import"crypto";import"net";import"url";import"fs";import"child_process";import"@likec4/core";import"fs/promises";import"events";import"node:fs/promises";import"node:stream";import"node:process";import"http";import"http2";import"stream";import"buffer";
|
|
2
|
+
import"string_decoder";import"node:crypto";import"node:buffer";import"node:http";import"@likec4/core/types";import"@hpcc-js/wasm-graphviz";import"@likec4/core/utils";import"@likec4/core/compute-view";import"boxen";import"node:child_process";import"node:events";import"node:stream/promises";import"node:readline/promises";import"node:os";function t(r){return o.create(r)}export{t as createLikeC4Model};
|