@likec4/core 1.32.2 → 1.34.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/dist/builder/index.d.mts +6 -4
- package/dist/builder/index.mjs +45 -13
- package/dist/compute-view/index.d.mts +6 -4
- package/dist/compute-view/index.mjs +33 -10
- package/dist/compute-view/relationships-view/index.d.mts +6 -4
- package/dist/compute-view/relationships-view/index.mjs +6 -3
- package/dist/index.d.mts +9 -138
- package/dist/index.mjs +31 -3712
- package/dist/model/connection/deployment/index.d.mts +10 -0
- package/dist/model/connection/deployment/index.mjs +18 -0
- package/dist/model/connection/index.d.mts +70 -0
- package/dist/model/connection/index.mjs +23 -0
- package/dist/model/connection/model/index.d.mts +10 -0
- package/dist/model/connection/model/index.mjs +11 -0
- package/dist/model/index.d.mts +14 -256
- package/dist/model/index.mjs +27 -5
- package/dist/shared/{core.cbA9VZ02.mjs → core.4SpVCM9m.mjs} +31 -1073
- package/dist/shared/{core.BuO4ncfY.d.mts → core.668kXpZq.d.mts} +42 -52
- package/dist/shared/core.8KM0D6va.mjs +33 -0
- package/dist/shared/core.B0oEIXqd.mjs +47 -0
- package/dist/shared/core.BH9nN-_I.mjs +22 -0
- package/dist/shared/core.BMCb0wJI.mjs +177 -0
- package/dist/shared/core.BTnf14gD.mjs +331 -0
- package/dist/shared/core.BgvIuGGU.mjs +3 -0
- package/dist/shared/core.BoyJPEen.mjs +21 -0
- package/dist/shared/{core.CUYDgv2-.mjs → core.Br7Fab9l.mjs} +12 -15
- package/dist/shared/{core.BrCnZFTn.mjs → core.Btl47GOn.mjs} +3 -3
- package/dist/shared/core.ByrmCl9I.mjs +5 -0
- package/dist/shared/core.C80Z37Eu.mjs +29 -0
- package/dist/shared/{core.Pf5I9o0e.d.mts → core.CF82MWyh.d.mts} +1 -1
- package/dist/shared/core.CJSFKrYf.d.mts +83 -0
- package/dist/shared/{core.rmvsy0n3.mjs → core.C_C-3c1S.mjs} +5 -198
- package/dist/shared/{core.DoK86JEe.mjs → core.CpwrZi3D.mjs} +2 -73
- package/dist/shared/{core.CpXlRyE5.mjs → core.CtKXPqN_.mjs} +5 -36
- package/dist/shared/core.CxGKeL-L.mjs +144 -0
- package/dist/shared/core.CzdwsPmY.d.mts +69 -0
- package/dist/shared/core.D3xEWj5B.d.mts +41 -0
- package/dist/shared/{core.Cy9smucx.mjs → core.D4npX2q8.mjs} +1 -3
- package/dist/shared/core.D56nCp7e.mjs +168 -0
- package/dist/shared/core.D5qVzkws.mjs +724 -0
- package/dist/shared/{core.CBxTtXMi.d.mts → core.DAj3LuFH.d.mts} +58 -57
- package/dist/shared/{core.Bk7wEZFG.mjs → core.DXRAwwDB.mjs} +3 -2
- package/dist/shared/core.DcS-0zys.mjs +10 -0
- package/dist/shared/core.Di7__sMg.d.mts +87 -0
- package/dist/shared/{core.DaAyklhe.d.mts → core.DrS4Bf4y.d.mts} +31 -22
- package/dist/shared/core.DsMrjY2q.mjs +34 -0
- package/dist/shared/core.DuSLYTG6.d.mts +57 -0
- package/dist/shared/{core.Bdz6fBF1.d.mts → core.IWLie-Ma.d.mts} +92 -81
- package/dist/shared/{core.CBpKAlhj.mjs → core.PqNe5WxQ.mjs} +96 -56
- package/dist/shared/core.XptQjhMA.mjs +1295 -0
- package/dist/shared/core.zLlww-07.mjs +3 -0
- package/dist/theme/index.d.mts +134 -0
- package/dist/theme/index.mjs +3709 -0
- package/dist/types/_aux.d.mts +4 -0
- package/dist/types/index.d.mts +9 -5
- package/dist/types/index.mjs +17 -146
- package/dist/utils/index.d.mts +15 -100
- package/dist/utils/index.mjs +25 -1315
- package/dist/utils/iterable/index.d.mts +100 -0
- package/dist/utils/iterable/index.mjs +24 -0
- package/package.json +29 -13
- package/src/builder/Builder.ts +13 -4
- package/src/builder/__snapshots__/Builder-style1.spec.ts.snap +0 -13
- package/src/builder/__snapshots__/Builder-style2.compute-model.json5 +2 -6
- package/src/builder/__snapshots__/Builder-style2.spec.ts.snap +0 -7
- package/src/compute-view/deployment-view/__test__/fixture.ts +15 -5
- package/src/compute-view/deployment-view/utils.ts +13 -13
- package/src/compute-view/dynamic-view/compute.ts +2 -1
- package/src/compute-view/element-view/__test__/__snapshots__/legacy.spec.ts.snap +2 -2
- package/src/compute-view/relationships-view/layout.ts +1 -1
- package/src/compute-view/utils/applyCustomElementProperties.ts +8 -0
- package/src/compute-view/utils/applyCustomRelationProperties.ts +2 -0
- package/src/compute-view/utils/buildComputedNodes.ts +4 -3
- package/src/compute-view/utils/merge-props-from-relationships.ts +6 -5
- package/src/compute-view/utils/view-hash.ts +24 -3
- package/src/model/DeploymentElementModel.ts +21 -17
- package/src/model/DeploymentModel.ts +1 -1
- package/src/model/ElementModel.ts +15 -5
- package/src/model/LikeC4Model.ts +1 -1
- package/src/model/RelationModel.ts +20 -17
- package/src/model/index.ts +2 -0
- package/src/model/types.ts +2 -1
- package/src/model/view/EdgeModel.ts +4 -3
- package/src/model/view/LikeC4ViewModel.ts +6 -1
- package/src/model/view/NodeModel.ts +5 -3
- package/src/theme/index.ts +12 -5
- package/src/types/RichText.ts +200 -0
- package/src/types/expression-model.ts +2 -2
- package/src/types/expression.ts +2 -2
- package/src/types/fqnRef.ts +2 -2
- package/src/types/global.ts +1 -1
- package/src/types/index.ts +4 -2
- package/src/types/model-data.ts +2 -2
- package/src/types/model-deployment.ts +6 -5
- package/src/types/model-dump.ts +1 -1
- package/src/types/model-logical.ts +5 -5
- package/src/types/model-spec.ts +2 -2
- package/src/types/operators.ts +2 -2
- package/src/types/scalar.ts +47 -2
- package/src/types/view-common.ts +3 -3
- package/src/types/view-computed.ts +4 -6
- package/src/types/view-layouted.ts +11 -2
- package/src/types/view-parsed.deployment.ts +1 -1
- package/src/types/view-parsed.dynamic.ts +2 -2
- package/src/types/view-parsed.element.ts +2 -2
- package/src/types/view.ts +2 -2
- package/src/utils/index.ts +4 -9
- package/src/utils/markdown/index.ts +2 -0
- package/src/utils/markdown/to-html.ts +32 -0
- package/src/utils/markdown/to-text.ts +14 -0
- package/dist/types/aux.d.mts +0 -3
- /package/dist/types/{aux.mjs → _aux.mjs} +0 -0
- /package/src/types/{aux.ts → _aux.ts} +0 -0
package/dist/builder/index.d.mts
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { LastArrayElement, Split, Simplify, IsLiteral, Writable, IfNever, IsNever, TupleToUnion, Tagged } from 'type-fest';
|
|
2
|
-
import {
|
|
3
|
-
import { D as DeploymentFqn, F as Fqn
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
2
|
+
import { g as LikeC4Model } from '../shared/core.DrS4Bf4y.mjs';
|
|
3
|
+
import { D as DeploymentFqn, F as Fqn } from '../shared/core.668kXpZq.mjs';
|
|
4
|
+
import { r as DeploymentElement, v as DeploymentRelationship, Q as Element, Z as ModelRelation, a8 as Participant, M as ModelFqnExpr, d as ModelRelationExpr, aF as AnyViewRuleStyle, aK as AutoLayoutDirection, E as Expression, al as ParsedView, b9 as ParsedDeploymentView, bp as ParsedElementView, n as ParsedLikeC4ModelData, _ as ElementSpecification$1, a1 as RelationshipSpecification, $ as TagSpecification } from '../shared/core.IWLie-Ma.mjs';
|
|
5
|
+
import { N as NonEmptyArray, K as KeysOf } from '../shared/core.DuSLYTG6.mjs';
|
|
6
|
+
import { c as ElementShape, h as ThemeColor, b as BorderStyle, a as ShapeSize, S as SpacingSize, T as TextSize, f as RelationshipArrowType, R as RelationshipLineType } from '../shared/core.CzdwsPmY.mjs';
|
|
7
|
+
import { a as Aux, S as SpecAux, A as Any } from '../shared/core.DAj3LuFH.mjs';
|
|
6
8
|
import '../shared/core.CywrQs86.mjs';
|
|
7
9
|
|
|
8
10
|
type ToNested$1<T, Id extends string> = T extends TypesNested<infer P, any, any, any, any, any, any, any, infer F> ? TypesNested<`${P}.${Id}`, T['ElementKind'], T['Fqn'], T['ViewId'], T['RelationshipKind'], T['Tag'], T['MetadataKey'], T['DeploymentKind'], `${P}.${Id}` | F> : T extends AnyTypes ? TypesNested<Id, T['ElementKind'], T['Fqn'], T['ViewId'], T['RelationshipKind'], T['Tag'], T['MetadataKey'], T['DeploymentKind'], Id | T['DeploymentFqn']> : never;
|
package/dist/builder/index.mjs
CHANGED
|
@@ -1,13 +1,36 @@
|
|
|
1
|
-
import { i, l, d, c as computeLikeC4Model } from '../shared/core.
|
|
2
|
-
import { m
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { l as l$1 } from '../shared/core.
|
|
1
|
+
import { i, l, d, c as computeLikeC4Model } from '../shared/core.PqNe5WxQ.mjs';
|
|
2
|
+
import { m } from '../shared/core.ByrmCl9I.mjs';
|
|
3
|
+
import { a as _type, t as n$1, _ as _stage, c as isDeployedInstance, F as FqnRef } from '../shared/core.Br7Fab9l.mjs';
|
|
4
|
+
import { t as t$2 } from '../shared/core.BH9nN-_I.mjs';
|
|
5
|
+
import { l as l$1 } from '../shared/core.8KM0D6va.mjs';
|
|
6
6
|
import { u } from '../shared/core.DbRvwARP.mjs';
|
|
7
|
-
import { t as t$1 } from '../shared/core.
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import '../shared/core.
|
|
7
|
+
import { t as t$1 } from '../shared/core.4SpVCM9m.mjs';
|
|
8
|
+
import { i as i$1 } from '../shared/core.CpwrZi3D.mjs';
|
|
9
|
+
import { n as nameFromFqn, k as isSameHierarchy, p as parentFqn } from '../shared/core.C_C-3c1S.mjs';
|
|
10
|
+
import { t } from '../shared/core.zLlww-07.mjs';
|
|
11
|
+
import { s as o, M as ModelFqnExpr, f as isElementView } from '../shared/core.DXRAwwDB.mjs';
|
|
12
|
+
import { i as invariant } from '../shared/core.D4npX2q8.mjs';
|
|
13
|
+
import { a as DefaultElementShape, D as DefaultThemeColor } from '../shared/core.D56nCp7e.mjs';
|
|
14
|
+
import '../shared/core.D5qVzkws.mjs';
|
|
15
|
+
import '../shared/core.C80Z37Eu.mjs';
|
|
16
|
+
import '../shared/core.B0oEIXqd.mjs';
|
|
17
|
+
import 'rehype-raw';
|
|
18
|
+
import 'rehype-sanitize';
|
|
19
|
+
import 'rehype-stringify';
|
|
20
|
+
import 'remark-gfm';
|
|
21
|
+
import 'remark-parse';
|
|
22
|
+
import 'remark-rehype';
|
|
23
|
+
import 'unified';
|
|
24
|
+
import 'mdast-util-from-markdown';
|
|
25
|
+
import 'mdast-util-to-string';
|
|
26
|
+
import '../shared/core.BTnf14gD.mjs';
|
|
27
|
+
import '../shared/core.BgvIuGGU.mjs';
|
|
28
|
+
import '../shared/core.BoyJPEen.mjs';
|
|
29
|
+
import '../shared/core.CtKXPqN_.mjs';
|
|
30
|
+
import '../shared/core.Btl47GOn.mjs';
|
|
31
|
+
import '../shared/core.BMCb0wJI.mjs';
|
|
32
|
+
import '../shared/core.DcS-0zys.mjs';
|
|
33
|
+
import '../shared/core.DsMrjY2q.mjs';
|
|
11
34
|
|
|
12
35
|
function n(...r){return u(Object.fromEntries,r)}
|
|
13
36
|
|
|
@@ -447,11 +470,10 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
447
470
|
return [{
|
|
448
471
|
id,
|
|
449
472
|
title,
|
|
450
|
-
description,
|
|
473
|
+
description: description ? { txt: description } : null,
|
|
451
474
|
tags,
|
|
452
475
|
links,
|
|
453
476
|
_stage: "parsed",
|
|
454
|
-
// customColorDefinitions: {},
|
|
455
477
|
...props
|
|
456
478
|
}, builder2];
|
|
457
479
|
};
|
|
@@ -605,6 +627,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
605
627
|
const {
|
|
606
628
|
title = "",
|
|
607
629
|
links: _links = [],
|
|
630
|
+
description = null,
|
|
608
631
|
...props
|
|
609
632
|
} = defu(
|
|
610
633
|
typeof _props === "string" ? { title: _props } : { ..._props },
|
|
@@ -619,6 +642,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
619
642
|
model: target
|
|
620
643
|
},
|
|
621
644
|
title,
|
|
645
|
+
...description && { description: { txt: description } },
|
|
622
646
|
...links && { links },
|
|
623
647
|
...props
|
|
624
648
|
});
|
|
@@ -630,6 +654,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
630
654
|
const {
|
|
631
655
|
title = "",
|
|
632
656
|
links: _links = [],
|
|
657
|
+
description = null,
|
|
633
658
|
...props
|
|
634
659
|
} = defu(
|
|
635
660
|
typeof _props === "string" ? { title: _props } : { ..._props },
|
|
@@ -641,6 +666,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
641
666
|
model: target
|
|
642
667
|
},
|
|
643
668
|
title,
|
|
669
|
+
...description && { description: { txt: description } },
|
|
644
670
|
...links && { links },
|
|
645
671
|
...props
|
|
646
672
|
});
|
|
@@ -656,6 +682,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
656
682
|
icon: _icon,
|
|
657
683
|
style,
|
|
658
684
|
title,
|
|
685
|
+
description = null,
|
|
659
686
|
...props
|
|
660
687
|
} = typeof _props === "string" ? { title: _props } : { ..._props };
|
|
661
688
|
const links = mapLinks(_links);
|
|
@@ -665,7 +692,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
665
692
|
id: _id,
|
|
666
693
|
kind,
|
|
667
694
|
title: title ?? nameFromFqn(_id),
|
|
668
|
-
description:
|
|
695
|
+
...description && { description: { txt: description } },
|
|
669
696
|
technology: null,
|
|
670
697
|
tags: [],
|
|
671
698
|
color: specStyle?.color ?? DefaultThemeColor,
|
|
@@ -815,6 +842,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
815
842
|
const {
|
|
816
843
|
links,
|
|
817
844
|
title,
|
|
845
|
+
description = null,
|
|
818
846
|
...props
|
|
819
847
|
} = typeof _props === "string" ? { title: _props } : { ..._props };
|
|
820
848
|
const _id = b.__deploymentFqn(id);
|
|
@@ -823,6 +851,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
823
851
|
id: _id,
|
|
824
852
|
element: target,
|
|
825
853
|
...title && { title },
|
|
854
|
+
...description && { description: { txt: description } },
|
|
826
855
|
...links && { links: mapLinks(links) },
|
|
827
856
|
...props
|
|
828
857
|
});
|
|
@@ -834,6 +863,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
834
863
|
const {
|
|
835
864
|
title = null,
|
|
836
865
|
links,
|
|
866
|
+
description = null,
|
|
837
867
|
...props
|
|
838
868
|
} = typeof _props === "string" ? { title: _props } : { ..._props };
|
|
839
869
|
b.__addDeploymentRelation({
|
|
@@ -844,6 +874,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
844
874
|
deployment: target
|
|
845
875
|
},
|
|
846
876
|
title,
|
|
877
|
+
...description && { description: { txt: description } },
|
|
847
878
|
...links && { links: mapLinks(links) },
|
|
848
879
|
...props
|
|
849
880
|
});
|
|
@@ -859,6 +890,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
859
890
|
icon: _icon,
|
|
860
891
|
style,
|
|
861
892
|
title,
|
|
893
|
+
description = null,
|
|
862
894
|
...props
|
|
863
895
|
} = typeof _props === "string" ? { title: _props } : { ..._props };
|
|
864
896
|
const icon = _icon ?? specStyle?.icon;
|
|
@@ -867,7 +899,7 @@ function builder(spec, _elements = /* @__PURE__ */ new Map(), _relations = [], _
|
|
|
867
899
|
id: _id,
|
|
868
900
|
kind,
|
|
869
901
|
title: title ?? nameFromFqn(_id),
|
|
870
|
-
description:
|
|
902
|
+
...description && { description: { txt: description } },
|
|
871
903
|
technology: null,
|
|
872
904
|
tags: null,
|
|
873
905
|
style: {
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import { A as Any } from '../shared/core.
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { A as Any } from '../shared/core.DAj3LuFH.mjs';
|
|
2
|
+
import { g as LikeC4Model } from '../shared/core.DrS4Bf4y.mjs';
|
|
3
|
+
import { n as ParsedLikeC4ModelData, C as ComputedLikeC4ModelData, al as ParsedView, ao as ComputedView } from '../shared/core.IWLie-Ma.mjs';
|
|
4
4
|
import 'type-fest';
|
|
5
|
-
import '../shared/core.
|
|
5
|
+
import '../shared/core.DuSLYTG6.mjs';
|
|
6
|
+
import '../shared/core.668kXpZq.mjs';
|
|
6
7
|
import '../shared/core.CywrQs86.mjs';
|
|
8
|
+
import '../shared/core.CzdwsPmY.mjs';
|
|
7
9
|
|
|
8
10
|
type ComputeViewResult<V> = {
|
|
9
11
|
isSuccess: true;
|
|
@@ -1,14 +1,37 @@
|
|
|
1
|
-
import { G as Graph, w as willCreateCycle, t as topologicalSortExports, i as i$2, l } from '../shared/core.
|
|
2
|
-
export { c as computeLikeC4Model, a as computeParsedModelData, b as computeView, u as unsafeComputeView } from '../shared/core.
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
1
|
+
import { G as Graph, w as willCreateCycle, t as topologicalSortExports, i as i$2, l } from '../shared/core.PqNe5WxQ.mjs';
|
|
2
|
+
export { c as computeLikeC4Model, a as computeParsedModelData, b as computeView, u as unsafeComputeView } from '../shared/core.PqNe5WxQ.mjs';
|
|
3
|
+
import { i as i$1 } from '../shared/core.D5qVzkws.mjs';
|
|
4
|
+
import { r } from '../shared/core.4SpVCM9m.mjs';
|
|
5
|
+
import { h as isExtendsElementView, f as isElementView } from '../shared/core.DXRAwwDB.mjs';
|
|
6
|
+
import { o as isNonEmptyArray } from '../shared/core.C_C-3c1S.mjs';
|
|
7
|
+
import { i } from '../shared/core.CpwrZi3D.mjs';
|
|
7
8
|
import { u } from '../shared/core.DbRvwARP.mjs';
|
|
8
|
-
import '../shared/core.
|
|
9
|
-
import '../shared/core.
|
|
10
|
-
import '../shared/core.
|
|
11
|
-
import '../shared/core.
|
|
9
|
+
import { m } from '../shared/core.ByrmCl9I.mjs';
|
|
10
|
+
import '../shared/core.BTnf14gD.mjs';
|
|
11
|
+
import '../shared/core.C80Z37Eu.mjs';
|
|
12
|
+
import '../shared/core.BgvIuGGU.mjs';
|
|
13
|
+
import '../shared/core.BoyJPEen.mjs';
|
|
14
|
+
import '../shared/core.BH9nN-_I.mjs';
|
|
15
|
+
import '../shared/core.D4npX2q8.mjs';
|
|
16
|
+
import '../shared/core.CtKXPqN_.mjs';
|
|
17
|
+
import '../shared/core.8KM0D6va.mjs';
|
|
18
|
+
import '../shared/core.D56nCp7e.mjs';
|
|
19
|
+
import '../shared/core.B0oEIXqd.mjs';
|
|
20
|
+
import 'rehype-raw';
|
|
21
|
+
import 'rehype-sanitize';
|
|
22
|
+
import 'rehype-stringify';
|
|
23
|
+
import 'remark-gfm';
|
|
24
|
+
import 'remark-parse';
|
|
25
|
+
import 'remark-rehype';
|
|
26
|
+
import 'unified';
|
|
27
|
+
import 'mdast-util-from-markdown';
|
|
28
|
+
import 'mdast-util-to-string';
|
|
29
|
+
import '../shared/core.Br7Fab9l.mjs';
|
|
30
|
+
import '../shared/core.zLlww-07.mjs';
|
|
31
|
+
import '../shared/core.Btl47GOn.mjs';
|
|
32
|
+
import '../shared/core.BMCb0wJI.mjs';
|
|
33
|
+
import '../shared/core.DcS-0zys.mjs';
|
|
34
|
+
import '../shared/core.DsMrjY2q.mjs';
|
|
12
35
|
|
|
13
36
|
function y(...t){return u(f,t)}function f(t,e){if(!i(e,1))return {...t};if(!i(e,2)){let{[e[0]]:r,...m}=t;return m}let o={...t};for(let r of e)delete o[r];return o}
|
|
14
37
|
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import { A as Any, U as Unknown, g as ElementId, V as ViewId } from '../../shared/core.
|
|
2
|
-
import { E as ElementModel, R as RelationshipModel,
|
|
1
|
+
import { A as Any, U as Unknown, g as ElementId, V as ViewId } from '../../shared/core.DAj3LuFH.mjs';
|
|
2
|
+
import { E as ElementModel, R as RelationshipModel, g as LikeC4Model } from '../../shared/core.DrS4Bf4y.mjs';
|
|
3
3
|
import 'type-fest';
|
|
4
|
-
import '../../shared/core.
|
|
4
|
+
import '../../shared/core.DuSLYTG6.mjs';
|
|
5
|
+
import '../../shared/core.668kXpZq.mjs';
|
|
5
6
|
import '../../shared/core.CywrQs86.mjs';
|
|
6
|
-
import '../../shared/core.
|
|
7
|
+
import '../../shared/core.IWLie-Ma.mjs';
|
|
8
|
+
import '../../shared/core.CzdwsPmY.mjs';
|
|
7
9
|
|
|
8
10
|
type RelationshipsViewData<M extends Any = Unknown> = {
|
|
9
11
|
incomers: ReadonlySet<ElementModel<M>>;
|
|
@@ -1,6 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { m as sortParentsFirst, j as isDescendantOf, i as isAncestor, C } from '../../shared/core.C_C-3c1S.mjs';
|
|
2
|
+
import { D as DefaultMap } from '../../shared/core.BMCb0wJI.mjs';
|
|
3
|
+
import { a as nonNullable, i as invariant } from '../../shared/core.D4npX2q8.mjs';
|
|
4
|
+
import { a as toSet, t as toArray, i as imap } from '../../shared/core.Btl47GOn.mjs';
|
|
5
|
+
import { i as ifilter } from '../../shared/core.BH9nN-_I.mjs';
|
|
6
|
+
import '../../shared/core.zLlww-07.mjs';
|
|
4
7
|
|
|
5
8
|
function treeFromElements(elements) {
|
|
6
9
|
const sorted = sortParentsFirst([...elements]);
|
package/dist/index.d.mts
CHANGED
|
@@ -1,141 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
export {
|
|
3
|
-
export { BiMap, DefaultWeakMap, LinkedList, MultiMap, Queue, Stack, commonHead, compareNatural, compareNaturalHierarchically, compareRelations, delay, difference, equalsSet, getOrCreate, hasAtLeast, ifilter, ifind, iflat, ihead, imap, intersection, invariant, ireduce, isIterable, isNonEmptyArray, isString, isome, iunique, memoizeProp, nonNullable, nonexhaustive, objectHash, promiseNextTick, stringHash, symmetricDifference, toArray, toSet, union } from './utils/index.mjs';
|
|
1
|
+
export { ElementColors, RelationshipColors, computeColorValues, defaultTheme } from './theme/index.mjs';
|
|
2
|
+
export { BiMap, DefaultWeakMap, LinkedList, MultiMap, Queue, Stack, commonHead, compareNatural, compareNaturalHierarchically, compareRelations, delay, difference, equalsSet, getOrCreate, hasAtLeast, intersection, invariant, isNonEmptyArray, isString, markdownToHtml, markdownToText, memoizeProp, nonNullable, nonexhaustive, objectHash, promiseNextTick, stringHash, symmetricDifference, union } from './utils/index.mjs';
|
|
4
3
|
export { D as DefaultMap } from './shared/core.CywrQs86.mjs';
|
|
5
|
-
export { A as Any, A as AnyAux,
|
|
6
|
-
export { A as AnyFqn, B as BuiltInIcon,
|
|
4
|
+
export { A as Any, A as AnyAux, a as Aux, E as ExtractOnStage, M as ModelStage, S as SpecAux, U as Unknown, b as UnknownComputed, c as UnknownLayouted, d as UnknownParsed, e as _stage, f as _type, _ as aux, i as isOnStage } from './shared/core.DAj3LuFH.mjs';
|
|
5
|
+
export { A as AnyFqn, B as BuiltInIcon, D as DeploymentFqn, b as DeploymentKind, j as EdgeId, E as ElementKind, F as Fqn, e as GlobalFqn, G as GroupElementKind, I as Icon, a as IconUrl, M as MarkdownOrString, N as NodeId, P as ProjectId, d as RelationId, R as RelationKind, c as RelationshipKind, k as StepEdgeId, S as StepEdgeIdLiteral, m as StepEdgeKind, T as Tag, V as ViewId, o as extractStep, f as flattenMarkdownOrString, g as isGlobalFqn, i as isGroupElementKind, n as isStepEdgeId, s as scalar, h as splitGlobalFqn, l as stepEdgeId } from './shared/core.668kXpZq.mjs';
|
|
6
|
+
export { W as AbstractRelationship, ad as AndOperator, aE as AnyExcludePredicate, aD as AnyIncludePredicate, aq as AnyView, aF as AnyViewRuleStyle, aK as AutoLayoutDirection, z as AuxFromDump, A as AuxFromLikeC4ModelData, B as BBox, aS as BaseParsedViewProperties, aR as BaseViewProperties, aZ as ComputedDeploymentView, a_ as ComputedDynamicView, aX as ComputedEdge, aY as ComputedElementView, C as ComputedLikeC4ModelData, aW as ComputedNode, ao as ComputedView, U as DefaultArrowType, I as DefaultElementShape, T as DefaultLineStyle, K as DefaultPaddingSize, V as DefaultRelationshipColor, J as DefaultShapeSize, N as DefaultTextSize, H as DefaultThemeColor, q as DeployedInstance, r as DeploymentElement, s as DeploymentElementRef, D as DeploymentElementStyle, p as DeploymentNode, w as DeploymentRelation, v as DeploymentRelationship, b5 as DeploymentViewExcludePredicate, b4 as DeploymentViewIncludePredicate, b6 as DeploymentViewPredicate, b8 as DeploymentViewRule, b7 as DeploymentViewRuleStyle, b0 as DiagramEdge, a$ as DiagramNode, am as DiagramView, be as DynamicViewIncludeRule, bb as DynamicViewParallelSteps, bf as DynamicViewRule, ba as DynamicViewStep, bd as DynamicViewStepOrParallel, Q as Element, _ as ElementSpecification, O as ElementStyle, bj as ElementViewExcludePredicate, bi as ElementViewIncludePredicate, bk as ElementViewPredicate, bo as ElementViewRule, bl as ElementViewRuleGroup, bn as ElementViewRuleStyle, a3 as EqualOperator, E as Expression, ai as Filterable, F as FqnExpr, f as FqnRef, j as GlobalDynamicPredicates, G as GlobalPredicateId, i as GlobalPredicates, k as GlobalStyleID, l as GlobalStyles, a6 as KindEqual, b2 as LayoutedDeploymentView, b3 as LayoutedDynamicView, b1 as LayoutedElementView, L as LayoutedLikeC4ModelData, am as LayoutedView, o as LikeC4ModelData, y as LikeC4ModelDump, al as LikeC4View, e as ModelExpression, M as ModelFqnExpr, m as ModelGlobals, Z as ModelRelation, d as ModelRelationExpr, aT as NodeNotation, ab as NotOperator, aj as OperatorPredicate, af as OrOperator, b9 as ParsedDeploymentView, bg as ParsedDynamicView, bp as ParsedElementView, n as ParsedLikeC4ModelData, al as ParsedView, a8 as Participant, a9 as ParticipantOperator, g as Point, P as PredicateSelector, ap as ProcessedView, h as RectBox, c as RelationExpr, Y as Relationship, a1 as RelationshipSpecification, R as RichText, a as RichTextEmpty, b as RichTextOrEmpty, x as SpecTypesFromDump, a2 as Specification, S as SpecificationDump, a4 as TagEqual, $ as TagSpecification, aO as ViewAutoLayout, aP as ViewManualLayout, ar as ViewOnStage, at as ViewRule, aM as ViewRuleAutoLayout, aI as ViewRuleGlobalPredicateRef, aG as ViewRuleGlobalStyle, au as ViewRulePredicate, aQ as ViewType, aV as ViewWithHash, aU as ViewWithNotation, as as ViewWithType, ah as WhereOperator, X as XYPoint, bc as getParallelStepsPrefix, ae as isAndOperator, aL as isAutoLayoutDirection, ax as isComputedView, u as isDeployedInstance, t as isDeploymentNode, aB as isDeploymentView, an as isDiagramView, aC as isDynamicView, bh as isDynamicViewParallelSteps, ay as isElementView, aA as isExtendsElementView, a7 as isKindEqual, an as isLayoutedView, ac as isNotOperator, ag as isOrOperator, aa as isParticipantOperator, az as isScopedElementView, a0 as isTagColorSpecified, a5 as isTagEqual, aN as isViewRuleAutoLayout, aJ as isViewRuleGlobalPredicateRef, aH as isViewRuleGlobalStyle, bm as isViewRuleGroup, av as isViewRulePredicate, aw as isViewRuleStyle, ak as whereOperatorAsPredicate } from './shared/core.IWLie-Ma.mjs';
|
|
7
|
+
export { C as Coalesce, E as ExclusiveUnion, I as IteratorLike, K as KeysOf, L as Link, b as NTuple, N as NonEmptyArray, a as NonEmptyReadonlyArray, P as Predicate } from './shared/core.DuSLYTG6.mjs';
|
|
8
|
+
export { b as BorderStyle, B as BorderStyles, i as Color, C as ColorLiteral, d as CustomColor, e as CustomColorDefinitions, c as ElementShape, E as ElementShapes, k as ElementThemeColorValues, l as ElementThemeColors, H as HexColor, L as LikeC4Theme, f as RelationshipArrowType, R as RelationshipLineType, m as RelationshipThemeColorValues, o as RelationshipThemeColors, a as ShapeSize, S as SpacingSize, T as TextSize, h as ThemeColor, n as ThemeColorValues, g as ThemeColors, j as isThemeColor } from './shared/core.CzdwsPmY.mjs';
|
|
7
9
|
export { ViewChange } from './types/index.mjs';
|
|
8
|
-
export { I as IterableContainer, R as ReorderedArray, a as ancestorsFqn, c as commonAncestor, b as compareByFqnHierarchically, d as compareFqnHierarchically, h as hierarchyDistance, e as hierarchyLevel, i as isAncestor, f as isDescendantOf, g as isSameHierarchy, n as nameFromFqn, p as parentFqn, s as sortByFqnHierarchically, j as sortNaturalByFqn, k as sortParentsFirst } from './shared/core.
|
|
10
|
+
export { I as IterableContainer, R as ReorderedArray, a as ancestorsFqn, c as commonAncestor, b as compareByFqnHierarchically, d as compareFqnHierarchically, h as hierarchyDistance, e as hierarchyLevel, i as isAncestor, f as isDescendantOf, g as isSameHierarchy, n as nameFromFqn, p as parentFqn, s as sortByFqnHierarchically, j as sortNaturalByFqn, k as sortParentsFirst } from './shared/core.CF82MWyh.mjs';
|
|
11
|
+
export { ifilter, ifind, iflat, ihead, imap, ireduce, isIterable, isome, iunique, toArray, toSet } from './utils/iterable/index.mjs';
|
|
9
12
|
import 'type-fest';
|
|
10
|
-
|
|
11
|
-
declare const ElementColors: {
|
|
12
|
-
readonly primary: {
|
|
13
|
-
fill: "#3b82f6";
|
|
14
|
-
stroke: "#2563eb";
|
|
15
|
-
hiContrast: "#eff6ff";
|
|
16
|
-
loContrast: "#bfdbfe";
|
|
17
|
-
};
|
|
18
|
-
readonly blue: {
|
|
19
|
-
fill: "#3b82f6";
|
|
20
|
-
stroke: "#2563eb";
|
|
21
|
-
hiContrast: "#eff6ff";
|
|
22
|
-
loContrast: "#bfdbfe";
|
|
23
|
-
};
|
|
24
|
-
readonly secondary: {
|
|
25
|
-
fill: "#0284c7";
|
|
26
|
-
stroke: "#0369a1";
|
|
27
|
-
hiContrast: "#f0f9ff";
|
|
28
|
-
loContrast: "#B6ECF7";
|
|
29
|
-
};
|
|
30
|
-
readonly sky: {
|
|
31
|
-
fill: "#0284c7";
|
|
32
|
-
stroke: "#0369a1";
|
|
33
|
-
hiContrast: "#f0f9ff";
|
|
34
|
-
loContrast: "#B6ECF7";
|
|
35
|
-
};
|
|
36
|
-
readonly muted: {
|
|
37
|
-
fill: "#64748b";
|
|
38
|
-
stroke: "#475569";
|
|
39
|
-
hiContrast: "#f8fafc";
|
|
40
|
-
loContrast: "#cbd5e1";
|
|
41
|
-
};
|
|
42
|
-
readonly slate: {
|
|
43
|
-
fill: "#64748b";
|
|
44
|
-
stroke: "#475569";
|
|
45
|
-
hiContrast: "#f8fafc";
|
|
46
|
-
loContrast: "#cbd5e1";
|
|
47
|
-
};
|
|
48
|
-
readonly gray: {
|
|
49
|
-
readonly fill: "#737373";
|
|
50
|
-
readonly stroke: "#525252";
|
|
51
|
-
readonly hiContrast: "#fafafa";
|
|
52
|
-
readonly loContrast: "#d4d4d4";
|
|
53
|
-
};
|
|
54
|
-
readonly red: {
|
|
55
|
-
readonly fill: "#AC4D39";
|
|
56
|
-
readonly stroke: "#853A2D";
|
|
57
|
-
readonly hiContrast: "#FBD3CB";
|
|
58
|
-
readonly loContrast: "#f5b2a3";
|
|
59
|
-
};
|
|
60
|
-
readonly green: {
|
|
61
|
-
readonly fill: "#428a4f";
|
|
62
|
-
readonly stroke: "#2d5d39";
|
|
63
|
-
readonly hiContrast: "#f8fafc";
|
|
64
|
-
readonly loContrast: "#c2f0c2";
|
|
65
|
-
};
|
|
66
|
-
readonly amber: {
|
|
67
|
-
readonly fill: "#A35829";
|
|
68
|
-
readonly stroke: "#7E451D";
|
|
69
|
-
readonly hiContrast: "#FFE0C2";
|
|
70
|
-
readonly loContrast: "#f9b27c";
|
|
71
|
-
};
|
|
72
|
-
readonly indigo: {
|
|
73
|
-
readonly fill: "#6366f1";
|
|
74
|
-
readonly stroke: "#4f46e5";
|
|
75
|
-
readonly hiContrast: "#eef2ff";
|
|
76
|
-
readonly loContrast: "#c7d2fe";
|
|
77
|
-
};
|
|
78
|
-
};
|
|
79
|
-
|
|
80
|
-
declare const RelationshipColors: {
|
|
81
|
-
amber: {
|
|
82
|
-
lineColor: "#b45309";
|
|
83
|
-
labelBgColor: "#78350f";
|
|
84
|
-
labelColor: "#FFE0C2";
|
|
85
|
-
};
|
|
86
|
-
blue: {
|
|
87
|
-
lineColor: "#3b82f6";
|
|
88
|
-
labelBgColor: "#172554";
|
|
89
|
-
labelColor: "#60a5fa";
|
|
90
|
-
};
|
|
91
|
-
gray: {
|
|
92
|
-
lineColor: "#6E6E6E";
|
|
93
|
-
labelBgColor: "#18191b";
|
|
94
|
-
labelColor: "#C6C6C6";
|
|
95
|
-
};
|
|
96
|
-
green: {
|
|
97
|
-
lineColor: "#15803d";
|
|
98
|
-
labelBgColor: "#052e16";
|
|
99
|
-
labelColor: "#22c55e";
|
|
100
|
-
};
|
|
101
|
-
indigo: {
|
|
102
|
-
lineColor: "#6366f1";
|
|
103
|
-
labelBgColor: "#1e1b4b";
|
|
104
|
-
labelColor: "#818cf8";
|
|
105
|
-
};
|
|
106
|
-
muted: {
|
|
107
|
-
lineColor: "#64748b";
|
|
108
|
-
labelBgColor: "#0f172a";
|
|
109
|
-
labelColor: "#cbd5e1";
|
|
110
|
-
};
|
|
111
|
-
primary: {
|
|
112
|
-
lineColor: "#3b82f6";
|
|
113
|
-
labelBgColor: "#172554";
|
|
114
|
-
labelColor: "#60a5fa";
|
|
115
|
-
};
|
|
116
|
-
red: {
|
|
117
|
-
lineColor: "#AC4D39";
|
|
118
|
-
labelBgColor: "#b91c1c";
|
|
119
|
-
labelColor: "#f5b2a3";
|
|
120
|
-
};
|
|
121
|
-
secondary: {
|
|
122
|
-
lineColor: "#0ea5e9";
|
|
123
|
-
labelBgColor: "#082f49";
|
|
124
|
-
labelColor: "#38bdf8";
|
|
125
|
-
};
|
|
126
|
-
sky: {
|
|
127
|
-
lineColor: "#0ea5e9";
|
|
128
|
-
labelBgColor: "#082f49";
|
|
129
|
-
labelColor: "#38bdf8";
|
|
130
|
-
};
|
|
131
|
-
slate: {
|
|
132
|
-
lineColor: "#64748b";
|
|
133
|
-
labelBgColor: "#0f172a";
|
|
134
|
-
labelColor: "#cbd5e1";
|
|
135
|
-
};
|
|
136
|
-
};
|
|
137
|
-
|
|
138
|
-
declare const defaultTheme: LikeC4Theme;
|
|
139
|
-
declare function computeColorValues(color: ColorLiteral): ThemeColorValues;
|
|
140
|
-
|
|
141
|
-
export { ColorLiteral, ElementColors, LikeC4Theme, RelationshipColors, ThemeColorValues, computeColorValues, defaultTheme };
|