likec4 1.48.0 → 1.49.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 +11 -1
- package/__app__/src/likec4.js +5595 -4127
- package/__app__/src/routes/index.js +3 -153
- package/__app__/src/routes/projects.js +21 -1087
- package/__app__/src/routes/single.js +1221 -16
- package/__app__/src/style.css +1 -1
- package/__app__/src/vendors.js +3507 -894
- package/__app__/src/webcomponent.js +1 -1
- package/config/schema.json +155 -143
- package/dist/THIRD-PARTY-LICENSES.md +1739 -0
- package/dist/_chunks/GraphvizBinaryAdapter.mjs +72 -0
- package/dist/_chunks/filenames.mjs +14 -0
- package/dist/_chunks/index.d.mts +224 -129
- package/dist/_chunks/index2.d.mts +2033 -1908
- package/dist/_chunks/libs/@chevrotain/gast.mjs +1 -3969
- package/dist/_chunks/libs/@chevrotain/regexp-to-ast.mjs +9 -785
- package/dist/_chunks/libs/@chevrotain/utils.mjs +1 -37
- package/dist/_chunks/libs/@hono/mcp.mjs +34 -0
- package/dist/_chunks/libs/@hono/node-server.mjs +1 -436
- package/dist/_chunks/libs/@logtape/logtape.d.mts +741 -0
- package/dist/_chunks/libs/@logtape/logtape.mjs +6 -1354
- package/dist/_chunks/libs/@lume/kiwi.mjs +1 -1355
- package/dist/_chunks/libs/@modelcontextprotocol/sdk.d.mts +14 -14
- package/dist/_chunks/libs/@modelcontextprotocol/sdk.mjs +12 -25105
- package/dist/_chunks/libs/@msgpack/msgpack.mjs +1 -1503
- package/dist/_chunks/libs/@nanostores/react.mjs +1 -30
- package/dist/_chunks/libs/@smithy/util-base64.mjs +1 -100
- package/dist/_chunks/libs/ajv.mjs +1 -777
- package/dist/_chunks/libs/atomically.mjs +1 -362
- package/dist/_chunks/libs/birpc.mjs +1 -201
- package/dist/_chunks/libs/chevrotain-allstar.mjs +2 -850
- package/dist/_chunks/libs/chevrotain.mjs +55 -6229
- package/dist/_chunks/libs/conf.mjs +1 -2258
- package/dist/_chunks/libs/defu.mjs +1 -42
- package/dist/_chunks/libs/esm-env.mjs +1 -5
- package/dist/_chunks/libs/eventemitter3.mjs +1 -243
- package/dist/_chunks/libs/fast-equals.mjs +1 -446
- package/dist/_chunks/libs/find-up-simple.mjs +1 -24
- package/dist/_chunks/libs/get-port.mjs +1 -107
- package/dist/_chunks/libs/is-docker.mjs +1 -26
- package/dist/_chunks/libs/is-error-instance.mjs +1 -26
- package/dist/_chunks/libs/is-inside-container.mjs +1 -20
- package/dist/_chunks/libs/is-plain-obj.mjs +1 -9
- package/dist/_chunks/libs/isexe.mjs +1 -127
- package/dist/_chunks/libs/json5.mjs +14 -959
- package/dist/_chunks/libs/khroma.mjs +1 -605
- package/dist/_chunks/libs/ky.mjs +2 -807
- package/dist/_chunks/libs/langium.d.mts +2880 -2844
- package/dist/_chunks/libs/langium.mjs +32 -20351
- package/dist/_chunks/libs/merge-error-cause.mjs +2 -746
- package/dist/_chunks/libs/nanostores.mjs +1 -198
- package/dist/_chunks/libs/p-limit.mjs +1 -120
- package/dist/_chunks/libs/p-queue.mjs +1 -449
- package/dist/_chunks/libs/package-manager-detector.mjs +1 -559
- package/dist/_chunks/libs/package-up.mjs +1 -10
- package/dist/_chunks/libs/parse-ms.mjs +1 -36
- package/dist/_chunks/libs/pathe.mjs +1 -0
- package/dist/_chunks/libs/picomatch.mjs +1 -1673
- package/dist/_chunks/libs/pretty-ms.mjs +1 -80
- package/dist/_chunks/libs/remeda.mjs +1 -690
- package/dist/_chunks/libs/safe-stringify.mjs +1 -21
- package/dist/_chunks/libs/strip-indent.mjs +1 -15
- package/dist/_chunks/libs/tinyrainbow.mjs +1 -88
- package/dist/_chunks/libs/ts-graphviz.mjs +4 -725
- package/dist/_chunks/libs/ufo.mjs +1 -240
- package/dist/_chunks/libs/which.mjs +1 -84
- package/dist/_chunks/libs/word-wrap.mjs +12 -43
- package/dist/_chunks/node.mjs +481 -0
- package/dist/_chunks/plugin.mjs +98 -772
- package/dist/_chunks/rolldown-runtime.mjs +1 -48
- package/dist/_chunks/sequence-view.mjs +1 -575
- package/dist/cli/index.mjs +127 -1846
- package/dist/config/index.d.mts +2 -2
- package/dist/config/index.mjs +1 -6
- package/dist/index.d.mts +148 -7
- package/dist/index.mjs +1 -21
- package/dist/model/builder.mjs +1 -3
- package/dist/model/index.d.mts +57 -3
- package/dist/model/index.mjs +1 -5
- package/dist/vite-plugin/index.d.mts +4 -3
- package/dist/vite-plugin/index.mjs +1 -22
- package/dist/vite-plugin/internal.d.mts +5 -5
- package/dist/vite-plugin/internal.mjs +1 -68
- package/package.json +60 -41
- package/react/{index.d.ts → index.d.mts} +112 -70
- package/react/{index.js → index.mjs} +21361 -22064
- package/react/package.json +2 -5
- package/vite-plugin-modules.d.ts +5 -5
- package/dist/_chunks/LikeC4.d.mts +0 -121
- package/dist/_chunks/LikeC4.mjs +0 -202
- package/dist/_chunks/config-app.prod.d.mts +0 -18
- package/dist/_chunks/config-app.prod.mjs +0 -188
- package/dist/_chunks/config-webcomponent.prod.mjs +0 -71
- package/dist/_chunks/define-config.mjs +0 -409
- package/dist/_chunks/index3.d.mts +0 -60
- package/dist/_chunks/index4.d.mts +0 -1
- package/dist/_chunks/libs/@smithy/is-array-buffer.mjs +0 -10
- package/dist/_chunks/libs/hono.mjs +0 -1829
- package/dist/_chunks/libs/nanoid.mjs +0 -29
- package/dist/_chunks/model.mjs +0 -12
- package/dist/_chunks/module.d.mts +0 -71
- package/dist/_chunks/module.mjs +0 -18657
- package/dist/_chunks/vite-build.mjs +0 -69
- package/dist/_chunks/vite-dev.mjs +0 -79
- package/dist/_chunks/vite-preview.mjs +0 -27
- package/dist/language/module.d.mts +0 -5
- package/dist/language/module.mjs +0 -20
- package/dist/vite/vite-build.d.mts +0 -26
- package/dist/vite/vite-build.mjs +0 -27
- package/dist/vite/vite-dev.d.mts +0 -34
- package/dist/vite/vite-dev.mjs +0 -29
- package/dist/vite/vite-preview.d.mts +0 -20
- package/dist/vite/vite-preview.mjs +0 -26
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import { webcrypto } from "node:crypto";
|
|
2
|
-
|
|
3
|
-
//#region ../../node_modules/.pnpm/nanoid@5.1.6/node_modules/nanoid/url-alphabet/index.js
|
|
4
|
-
const urlAlphabet = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";
|
|
5
|
-
|
|
6
|
-
//#endregion
|
|
7
|
-
//#region ../../node_modules/.pnpm/nanoid@5.1.6/node_modules/nanoid/index.js
|
|
8
|
-
const POOL_SIZE_MULTIPLIER = 128;
|
|
9
|
-
let pool, poolOffset;
|
|
10
|
-
function fillPool(bytes) {
|
|
11
|
-
if (!pool || pool.length < bytes) {
|
|
12
|
-
pool = Buffer.allocUnsafe(bytes * POOL_SIZE_MULTIPLIER);
|
|
13
|
-
webcrypto.getRandomValues(pool);
|
|
14
|
-
poolOffset = 0;
|
|
15
|
-
} else if (poolOffset + bytes > pool.length) {
|
|
16
|
-
webcrypto.getRandomValues(pool);
|
|
17
|
-
poolOffset = 0;
|
|
18
|
-
}
|
|
19
|
-
poolOffset += bytes;
|
|
20
|
-
}
|
|
21
|
-
function nanoid(size = 21) {
|
|
22
|
-
fillPool(size |= 0);
|
|
23
|
-
let id = "";
|
|
24
|
-
for (let i = poolOffset - size; i < poolOffset; i++) id += urlAlphabet[pool[i] & 63];
|
|
25
|
-
return id;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
//#endregion
|
|
29
|
-
export { nanoid as t };
|
package/dist/_chunks/model.mjs
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { Connection, ConnectionModel, DeployedInstanceModel, DeploymentConnectionModel, DeploymentNodeModel, DeploymentRelationModel as DeploymentRelationModel$1, EdgeModel, ElementModel as ElementModel$1, LikeC4DeploymentModel, LikeC4Model, LikeC4Model as LikeC4Model$1, LikeC4ViewModel as LikeC4ViewModel$1, NodeModel, RelationshipModel as RelationshipModel$1, deploymentConnection, differenceConnections, findAscendingConnections, findDeepestNestedConnection, findDescendantConnections, hasSameSource, hasSameSourceTarget, hasSameTarget, isAnyInOut, isDeployedInstanceModel, isDeploymentElementModel as isDeploymentElementModel$1, isDeploymentNodeModel, isDeploymentRelationModel as isDeploymentRelationModel$1, isEdgeModel, isElementModel as isElementModel$1, isIncoming, isLikeC4ViewModel as isLikeC4ViewModel$1, isNestedConnection, isNestedElementOfDeployedInstanceModel, isNodeModel, isOutgoing, isRelationModel as isRelationModel$1, mergeConnections, modelConnection as modelConnection$1, sortConnectionsByBoundaryHierarchy, sortDeepestFirst } from "@likec4/core/model";
|
|
2
|
-
|
|
3
|
-
//#region src/model/index.ts
|
|
4
|
-
/**
|
|
5
|
-
* Used by vite plugin to generate `virtual:likec4/model`
|
|
6
|
-
*/
|
|
7
|
-
function createLikeC4Model(model) {
|
|
8
|
-
return LikeC4Model.create(model);
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
//#endregion
|
|
12
|
-
export { isIncoming as A, sortDeepestFirst as B, isAnyInOut as C, isDeploymentRelationModel$1 as D, isDeploymentNodeModel as E, isOutgoing as F, isRelationModel$1 as I, mergeConnections as L, isNestedConnection as M, isNestedElementOfDeployedInstanceModel as N, isEdgeModel as O, isNodeModel as P, modelConnection$1 as R, hasSameTarget as S, isDeploymentElementModel$1 as T, findAscendingConnections as _, DeploymentNodeModel as a, hasSameSource as b, ElementModel$1 as c, LikeC4ViewModel$1 as d, NodeModel as f, differenceConnections as g, deploymentConnection as h, DeploymentConnectionModel as i, isLikeC4ViewModel$1 as j, isElementModel$1 as k, LikeC4DeploymentModel as l, createLikeC4Model as m, ConnectionModel as n, DeploymentRelationModel$1 as o, RelationshipModel$1 as p, DeployedInstanceModel as r, EdgeModel as s, Connection as t, LikeC4Model$1 as u, findDeepestNestedConnection as v, isDeployedInstanceModel as w, hasSameSourceTarget as x, findDescendantConnections as y, sortConnectionsByBoundaryHierarchy as z };
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
import { Ct as WorkspaceFolder, Et as Module, y as DeepPartial } from "./libs/langium.mjs";
|
|
2
|
-
import { n as LikeC4Services } from "./index2.mjs";
|
|
3
|
-
import "boxen";
|
|
4
|
-
import { LogErrorOptions, LogType } from "vite";
|
|
5
|
-
|
|
6
|
-
//#region src/logger.d.ts
|
|
7
|
-
declare function createLikeC4Logger(prefix: string | readonly [string, ...string[]]): {
|
|
8
|
-
info(msg: string): void;
|
|
9
|
-
warn(msg: unknown): void;
|
|
10
|
-
warnOnce(msg: string): void;
|
|
11
|
-
error(msg: unknown, options?: LogErrorOptions): void;
|
|
12
|
-
clearScreen: (_type: LogType) => void;
|
|
13
|
-
hasErrorLogged: (_error: any) => boolean;
|
|
14
|
-
hasWarned: boolean;
|
|
15
|
-
};
|
|
16
|
-
type ViteLogger = ReturnType<typeof createLikeC4Logger>;
|
|
17
|
-
type Logger = {
|
|
18
|
-
info(msg: string): void;
|
|
19
|
-
warn(msg: unknown): void;
|
|
20
|
-
error(err: unknown): void;
|
|
21
|
-
};
|
|
22
|
-
//#endregion
|
|
23
|
-
//#region src/language/Workspace.d.ts
|
|
24
|
-
declare class CliWorkspace {
|
|
25
|
-
private services;
|
|
26
|
-
private isInitialized;
|
|
27
|
-
constructor(services: CliServices);
|
|
28
|
-
initWorkspace(workspace: WorkspaceFolder): Promise<void>;
|
|
29
|
-
}
|
|
30
|
-
//#endregion
|
|
31
|
-
//#region src/language/module.d.ts
|
|
32
|
-
type CliAddedServices = {
|
|
33
|
-
logger: Logger;
|
|
34
|
-
cli: {
|
|
35
|
-
Workspace: CliWorkspace;
|
|
36
|
-
};
|
|
37
|
-
};
|
|
38
|
-
type CliServices = LikeC4Services & CliAddedServices;
|
|
39
|
-
declare const CliModule: Module<CliServices, DeepPartial<LikeC4Services> & CliAddedServices>;
|
|
40
|
-
type CreateLanguageServiceOptions = {
|
|
41
|
-
/**
|
|
42
|
-
* Whether to use the file system for the language service.
|
|
43
|
-
* @default true
|
|
44
|
-
*/
|
|
45
|
-
useFileSystem?: boolean;
|
|
46
|
-
/**
|
|
47
|
-
* Whether to watch for changes in the workspace.
|
|
48
|
-
* @default false
|
|
49
|
-
*/
|
|
50
|
-
watch?: boolean;
|
|
51
|
-
/**
|
|
52
|
-
* Logger to use for the language service.
|
|
53
|
-
* @default 'default'
|
|
54
|
-
*/
|
|
55
|
-
logger?: Logger | 'vite' | 'default' | false;
|
|
56
|
-
/**
|
|
57
|
-
* Whether to use the `dot` binary for layouting or the WebAssembly version.
|
|
58
|
-
* @default 'wasm'
|
|
59
|
-
*/
|
|
60
|
-
graphviz?: 'wasm' | 'binary';
|
|
61
|
-
/**
|
|
62
|
-
* Whether to start MCP server
|
|
63
|
-
* @default false
|
|
64
|
-
*/
|
|
65
|
-
mcp?: false | 'stdio' | {
|
|
66
|
-
port: number;
|
|
67
|
-
};
|
|
68
|
-
};
|
|
69
|
-
declare function createLanguageServices(opts?: CreateLanguageServiceOptions): CliServices;
|
|
70
|
-
//#endregion
|
|
71
|
-
export { createLanguageServices as a, CreateLanguageServiceOptions as i, CliModule as n, Logger as o, CliServices as r, ViteLogger as s, CliAddedServices as t };
|