@likec4/core 1.26.2 → 1.27.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/builder/index.d.mts +3 -1
- package/dist/builder/index.mjs +6 -4
- package/dist/compute-view/index.d.mts +1 -2
- package/dist/compute-view/index.mjs +6 -6
- package/dist/compute-view/relationships-view/index.d.mts +42 -0
- package/dist/compute-view/relationships-view/index.mjs +181 -0
- package/dist/index.d.mts +3 -5
- package/dist/index.mjs +5 -5
- package/dist/model/index.d.mts +3 -3
- package/dist/model/index.mjs +1 -1
- package/dist/shared/{core.yND74qFI.mjs → core.BMep80lJ.mjs} +2 -1
- package/dist/shared/{core.DRxv3HIl.mjs → core.C-YXI-43.mjs} +1 -5
- package/dist/shared/core.CQXU9DF7.mjs +477 -0
- package/dist/shared/{core.Brmu7VBL.d.mts → core.CtloVwbo.d.mts} +3 -1
- package/dist/shared/{core.DvRnF4Sc.mjs → core.Cu-UdkSl.mjs} +16 -477
- package/dist/shared/core.DbRvwARP.mjs +5 -0
- package/dist/shared/{core.oI7caxVx.d.mts → core.Uz54YXx0.d.mts} +1 -1
- package/dist/shared/{core.NNojPYtn.mjs → core.zj2huD5x.mjs} +12 -8
- package/dist/types/index.mjs +1 -1
- package/dist/utils/index.d.mts +3 -2
- package/dist/utils/index.mjs +5 -3
- package/package.json +19 -9
- package/src/builder/Builder.model.ts +74 -0
- package/src/compute-view/deployment-view/_types.ts +1 -1
- package/src/compute-view/deployment-view/predicates/relation-direct.ts +6 -7
- package/src/compute-view/deployment-view/predicates/relation-incoming.ts +2 -1
- package/src/compute-view/deployment-view/predicates/relation-outgoing.ts +1 -1
- package/src/compute-view/index.ts +0 -1
- package/src/compute-view/relationships-view/_types.ts +7 -6
- package/src/compute-view/relationships-view/compute.ts +140 -52
- package/src/compute-view/relationships-view/index.ts +3 -0
- package/src/compute-view/relationships-view/utils.ts +44 -11
- package/src/compute-view/utils/view-hash.ts +1 -4
- package/src/index.ts +1 -1
- package/src/model/ElementModel.ts +2 -0
- package/src/model/view/NodeModel.ts +5 -0
- package/src/utils/object-hash.ts +13 -2
- package/dist/builder/index.d.ts +0 -509
- package/dist/compute-view/index.d.ts +0 -23
- package/dist/index.d.ts +0 -147
- package/dist/model/index.d.ts +0 -118
- package/dist/shared/core.-qjOvsEL.d.ts +0 -146
- package/dist/shared/core.30yYKXcZ.d.ts +0 -186
- package/dist/shared/core.BH59D8Ji.d.ts +0 -858
- package/dist/shared/core.C8xqv5sq.mjs +0 -37
- package/dist/shared/core.CIbWBWW3.d.ts +0 -127
- package/dist/shared/core.Cpd5mZgF.d.ts +0 -732
- package/dist/shared/core.Dd1nCiNx.d.mts +0 -12
- package/dist/shared/core.mD0TIdz_.d.ts +0 -12
- package/dist/types/index.d.ts +0 -72
- package/dist/utils/index.d.ts +0 -458
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
export { C as ComputeViewResult, c as computeView, a as computeViews, u as unsafeComputeView } from '../shared/core.Cpd5mZgF.js';
|
|
2
|
-
export { c as computeRelationshipsView } from '../shared/core.mD0TIdz_.js';
|
|
3
|
-
import { L as LikeC4View, C as ComputedLikeC4ModelData, a as ComputedView } from '../shared/core.BH59D8Ji.js';
|
|
4
|
-
import 'type-fest';
|
|
5
|
-
import '../shared/core.30yYKXcZ.js';
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* Resolve rules of extended views
|
|
9
|
-
* (Removes invalid views)
|
|
10
|
-
*/
|
|
11
|
-
declare function resolveRulesExtendedViews<V extends Record<any, LikeC4View>>(unresolvedViews: V): V;
|
|
12
|
-
|
|
13
|
-
/**
|
|
14
|
-
* Convert hashed edge ids to human-readable
|
|
15
|
-
* Mostly for testing purposes
|
|
16
|
-
*/
|
|
17
|
-
declare function withReadableEdges<T extends ComputedView>({ edges, nodes, ...view }: T, separator?: string): T & {
|
|
18
|
-
nodeIds: string[];
|
|
19
|
-
edgeIds: string[];
|
|
20
|
-
};
|
|
21
|
-
declare function viewsWithReadableEdges<M extends ComputedLikeC4ModelData>({ views, ...model }: M): M;
|
|
22
|
-
|
|
23
|
-
export { resolveRulesExtendedViews, viewsWithReadableEdges, withReadableEdges };
|
package/dist/index.d.ts
DELETED
|
@@ -1,147 +0,0 @@
|
|
|
1
|
-
import { H as HexColorLiteral, T as ThemeColorValues, L as LikeC4Theme } from './shared/core.30yYKXcZ.js';
|
|
2
|
-
export { A as AsFqn, l as BorderStyle, B as BorderStyles, x as Color, y as ColorLiteral, C as CustomColor, D as DefaultElementShape, f as DefaultPaddingSize, g as DefaultShapeSize, h as DefaultTextSize, i as DefaultThemeColor, m as Element, j as ElementKind, n as ElementKindSpecification, o as ElementKindSpecificationStyle, p as ElementShape, k as ElementShapes, q as ElementStyle, G as ElementThemeColorValues, z as ElementThemeColors, E as ExclusiveUnion, F as Fqn, I as IconUrl, a as IteratorLike, K as KeysOf, r as Link, c as NTuple, N as NonEmptyArray, b as NonEmptyReadonlyArray, P as Point, d as Predicate, e as ProjectId, J as RelationshipThemeColorValues, R as RelationshipThemeColors, S as ShapeSize, M as SpacingSize, s as Tag, t as TagSpec, O as TextSize, Q as ThemeColor, w as ThemeColors, u as TypedElement, X as XYPoint, v as isThemeColor } from './shared/core.30yYKXcZ.js';
|
|
3
|
-
export { aw as AbstractRelation, ah as AllNever, ai as AndOperator, a5 as AnyParsedLikeC4ModelData, aX as AutoLayoutDirection, a_ as BBox, aY as BasicElementView, aZ as BasicView, a$ as ComputedDeploymentView, b0 as ComputedDynamicView, b1 as ComputedEdge, b2 as ComputedElementView, C as ComputedLikeC4ModelData, aD as ComputedNode, a as ComputedView, b3 as CustomColorDefinitions, A as CustomElementExpr, B as CustomRelationExpr, at as DefaultArrowType, au as DefaultLineStyle, av as DefaultRelationshipColor, b as DeployedInstance, D as DeploymentElement, c as DeploymentElementStyle, d as DeploymentNode, f as DeploymentNodeKind, g as DeploymentNodeKindSpecification, h as DeploymentRef, i as DeploymentRelation, b4 as DeploymentView, b5 as DeploymentViewRule, b6 as DeploymentViewRulePredicate, b7 as DeploymentViewRuleStyle, b8 as DiagramEdge, aE as DiagramNode, b9 as DiagramView, E as DirectRelationExpr, ba as DynamicView, bb as DynamicViewIncludeRule, bc as DynamicViewParallelSteps, bd as DynamicViewRule, be as DynamicViewStep, bf as DynamicViewStepOrParallel, bg as EdgeId, F as ElementExpression, G as ElementKindExpr, bA as ElementNotation, H as ElementPredicateExpression, I as ElementRefExpr, J as ElementTagExpr, bh as ElementView, K as ElementWhereExpr, aj as EqualOperator, M as ExpandedElementExpr, e as Expr, N as Expression, X as ExpressionV2, bi as ExtendsElementView, ak as Filterable, Y as FqnExpr, Z as FqnRef, a6 as GenericLikeC4ModelData, $ as GlobalDynamicPredicates, a0 as GlobalPredicateId, a1 as GlobalPredicates, a2 as GlobalStyleID, a3 as GlobalStyles, Q as InOutExpr, O as IncomingExpr, al as KindEqual, a7 as LayoutedLikeC4ModelData, a8 as LikeC4ModelDump, L as LikeC4View, a4 as ModelGlobals, ax as ModelRelation, bj as NodeId, R as NonWilcard, am as NotOperator, an as OperatorPredicate, ao as OrOperator, S as OutgoingExpr, a9 as ParsedLikeC4ModelData, ap as Participant, aq as ParticipantOperator, P as PredicateSelector, _ as RelationExpr, T as RelationExpression, ay as RelationId, U as RelationPredicateExpression, V as RelationWhereExpr, az as RelationshipArrowType, aA as RelationshipKind, aB as RelationshipKindSpecification, aC as RelationshipLineType, bk as ScopedElementView, bl as StepEdgeId, bm as StepEdgeIdLiteral, ar as TagEqual, bn as ViewAutoLayout, bo as ViewId, bp as ViewManualLayout, bq as ViewRule, br as ViewRuleAutoLayout, bs as ViewRuleGlobalPredicateRef, bt as ViewRuleGlobalStyle, bu as ViewRuleGroup, bv as ViewRulePredicate, bw as ViewRuleStyle, bx as ViewRuleStyleOrGlobalRef, by as ViewWithHash, bz as ViewWithNotation, as as WhereOperator, W as WildcardExpr, aF as extractStep, aG as getBBoxCenter, aH as getParallelStepsPrefix, aa as isAndOperator, aI as isAutoLayoutDirection, j as isCustomElement, k as isCustomRelationExpr, aJ as isDeploymentView, aK as isDynamicView, aL as isDynamicViewParallelSteps, l as isElement, m as isElementKindExpr, n as isElementPredicateExpr, o as isElementRef, p as isElementTagExpr, aM as isElementView, q as isElementWhere, r as isExpandedElementExpr, aN as isExtendsElementView, t as isInOut, s as isIncoming, ab as isKindEqual, ac as isNotOperator, ad as isOrOperator, u as isOutgoing, ae as isParticipantOperator, v as isRelation, w as isRelationExpression, x as isRelationPredicateExpr, y as isRelationWhere, aO as isScopedElementView, aP as isStepEdgeId, af as isTagEqual, aQ as isViewRuleAutoLayout, aR as isViewRuleGlobalPredicateRef, aS as isViewRuleGlobalStyle, aT as isViewRuleGroup, aU as isViewRulePredicate, aV as isViewRuleStyle, z as isWildcard, aW as stepEdgeId, ag as whereOperatorAsPredicate } from './shared/core.BH59D8Ji.js';
|
|
4
|
-
export { BiMap, DefaultMap, DefaultWeakMap, LinkedList, MultiMap, Queue, Stack, commonHead, compareNatural, compareRelations, delay, difference, equalsSet, getOrCreate, hasAtLeast, ifilter, ifind, iflat, imap, intersection, ireduce, isIterable, isNonEmptyArray, isString, isome, iunique, stringHash, symmetricDifference, toArray, toSet, union } from './utils/index.js';
|
|
5
|
-
export { A as AnyAux, b as Aux, C as ComputeViewResult, D as DeployedInstanceModel, d as DeploymentElementModel, e as DeploymentNodeModel, f as DeploymentRelationModel, g as EdgeModel, E as ElementModel, h as LikeC4DeploymentModel, L as LikeC4Model, i as LikeC4ViewModel, N as NodeModel, R as RelationshipModel, c as computeView, a as computeViews, u as unsafeComputeView } from './shared/core.Cpd5mZgF.js';
|
|
6
|
-
export { C as Connection, a as ConnectionModel, D as DeploymentConnectionModel } from './shared/core.-qjOvsEL.js';
|
|
7
|
-
export { c as computeRelationshipsView } from './shared/core.mD0TIdz_.js';
|
|
8
|
-
export { OverviewGraph, ViewChange } from './types/index.js';
|
|
9
|
-
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.CIbWBWW3.js';
|
|
10
|
-
export { default as objectHash } from '/home/runner/work/likec4/likec4/node_modules/.pnpm/@types+object-hash@3.0.6/node_modules/@types/object-hash/index.d.ts';
|
|
11
|
-
import 'type-fest';
|
|
12
|
-
|
|
13
|
-
declare const ElementColors: {
|
|
14
|
-
readonly primary: {
|
|
15
|
-
fill: "#3b82f6";
|
|
16
|
-
stroke: "#2563eb";
|
|
17
|
-
hiContrast: "#eff6ff";
|
|
18
|
-
loContrast: "#bfdbfe";
|
|
19
|
-
};
|
|
20
|
-
readonly blue: {
|
|
21
|
-
fill: "#3b82f6";
|
|
22
|
-
stroke: "#2563eb";
|
|
23
|
-
hiContrast: "#eff6ff";
|
|
24
|
-
loContrast: "#bfdbfe";
|
|
25
|
-
};
|
|
26
|
-
readonly secondary: {
|
|
27
|
-
fill: "#0284c7";
|
|
28
|
-
stroke: "#0369a1";
|
|
29
|
-
hiContrast: "#f0f9ff";
|
|
30
|
-
loContrast: "#B6ECF7";
|
|
31
|
-
};
|
|
32
|
-
readonly sky: {
|
|
33
|
-
fill: "#0284c7";
|
|
34
|
-
stroke: "#0369a1";
|
|
35
|
-
hiContrast: "#f0f9ff";
|
|
36
|
-
loContrast: "#B6ECF7";
|
|
37
|
-
};
|
|
38
|
-
readonly muted: {
|
|
39
|
-
fill: "#64748b";
|
|
40
|
-
stroke: "#475569";
|
|
41
|
-
hiContrast: "#f8fafc";
|
|
42
|
-
loContrast: "#cbd5e1";
|
|
43
|
-
};
|
|
44
|
-
readonly slate: {
|
|
45
|
-
fill: "#64748b";
|
|
46
|
-
stroke: "#475569";
|
|
47
|
-
hiContrast: "#f8fafc";
|
|
48
|
-
loContrast: "#cbd5e1";
|
|
49
|
-
};
|
|
50
|
-
readonly gray: {
|
|
51
|
-
readonly fill: "#737373";
|
|
52
|
-
readonly stroke: "#525252";
|
|
53
|
-
readonly hiContrast: "#fafafa";
|
|
54
|
-
readonly loContrast: "#d4d4d4";
|
|
55
|
-
};
|
|
56
|
-
readonly red: {
|
|
57
|
-
readonly fill: "#AC4D39";
|
|
58
|
-
readonly stroke: "#853A2D";
|
|
59
|
-
readonly hiContrast: "#FBD3CB";
|
|
60
|
-
readonly loContrast: "#f5b2a3";
|
|
61
|
-
};
|
|
62
|
-
readonly green: {
|
|
63
|
-
readonly fill: "#428a4f";
|
|
64
|
-
readonly stroke: "#2d5d39";
|
|
65
|
-
readonly hiContrast: "#f8fafc";
|
|
66
|
-
readonly loContrast: "#c2f0c2";
|
|
67
|
-
};
|
|
68
|
-
readonly amber: {
|
|
69
|
-
readonly fill: "#A35829";
|
|
70
|
-
readonly stroke: "#7E451D";
|
|
71
|
-
readonly hiContrast: "#FFE0C2";
|
|
72
|
-
readonly loContrast: "#f9b27c";
|
|
73
|
-
};
|
|
74
|
-
readonly indigo: {
|
|
75
|
-
readonly fill: "#6366f1";
|
|
76
|
-
readonly stroke: "#4f46e5";
|
|
77
|
-
readonly hiContrast: "#eef2ff";
|
|
78
|
-
readonly loContrast: "#c7d2fe";
|
|
79
|
-
};
|
|
80
|
-
};
|
|
81
|
-
|
|
82
|
-
declare const RelationshipColors: {
|
|
83
|
-
amber: {
|
|
84
|
-
lineColor: "#b45309";
|
|
85
|
-
labelBgColor: "#78350f";
|
|
86
|
-
labelColor: "#FFE0C2";
|
|
87
|
-
};
|
|
88
|
-
blue: {
|
|
89
|
-
lineColor: "#3b82f6";
|
|
90
|
-
labelBgColor: "#172554";
|
|
91
|
-
labelColor: "#60a5fa";
|
|
92
|
-
};
|
|
93
|
-
gray: {
|
|
94
|
-
lineColor: "#6E6E6E";
|
|
95
|
-
labelBgColor: "#18191b";
|
|
96
|
-
labelColor: "#C6C6C6";
|
|
97
|
-
};
|
|
98
|
-
green: {
|
|
99
|
-
lineColor: "#15803d";
|
|
100
|
-
labelBgColor: "#052e16";
|
|
101
|
-
labelColor: "#22c55e";
|
|
102
|
-
};
|
|
103
|
-
indigo: {
|
|
104
|
-
lineColor: "#6366f1";
|
|
105
|
-
labelBgColor: "#1e1b4b";
|
|
106
|
-
labelColor: "#818cf8";
|
|
107
|
-
};
|
|
108
|
-
muted: {
|
|
109
|
-
lineColor: "#64748b";
|
|
110
|
-
labelBgColor: "#0f172a";
|
|
111
|
-
labelColor: "#cbd5e1";
|
|
112
|
-
};
|
|
113
|
-
primary: {
|
|
114
|
-
lineColor: "#3b82f6";
|
|
115
|
-
labelBgColor: "#172554";
|
|
116
|
-
labelColor: "#60a5fa";
|
|
117
|
-
};
|
|
118
|
-
red: {
|
|
119
|
-
lineColor: "#AC4D39";
|
|
120
|
-
labelBgColor: "#b91c1c";
|
|
121
|
-
labelColor: "#f5b2a3";
|
|
122
|
-
};
|
|
123
|
-
secondary: {
|
|
124
|
-
lineColor: "#0ea5e9";
|
|
125
|
-
labelBgColor: "#082f49";
|
|
126
|
-
labelColor: "#38bdf8";
|
|
127
|
-
};
|
|
128
|
-
sky: {
|
|
129
|
-
lineColor: "#0ea5e9";
|
|
130
|
-
labelBgColor: "#082f49";
|
|
131
|
-
labelColor: "#38bdf8";
|
|
132
|
-
};
|
|
133
|
-
slate: {
|
|
134
|
-
lineColor: "#64748b";
|
|
135
|
-
labelBgColor: "#0f172a";
|
|
136
|
-
labelColor: "#cbd5e1";
|
|
137
|
-
};
|
|
138
|
-
};
|
|
139
|
-
|
|
140
|
-
declare const defaultTheme: LikeC4Theme;
|
|
141
|
-
declare function computeColorValues(color: HexColorLiteral): ThemeColorValues;
|
|
142
|
-
|
|
143
|
-
declare function nonNullable<T>(value: T, message?: string | (() => string)): NonNullable<T>;
|
|
144
|
-
declare function invariant(condition: any, message?: string): asserts condition;
|
|
145
|
-
declare function nonexhaustive(value: never): never;
|
|
146
|
-
|
|
147
|
-
export { ElementColors, HexColorLiteral, LikeC4Theme, RelationshipColors, ThemeColorValues, computeColorValues, defaultTheme, invariant, nonNullable, nonexhaustive };
|
package/dist/model/index.d.ts
DELETED
|
@@ -1,118 +0,0 @@
|
|
|
1
|
-
import { A as AnyAux, d as DeploymentElementModel, E as ElementModel, D as DeployedInstanceModel, e as DeploymentNodeModel } from '../shared/core.Cpd5mZgF.js';
|
|
2
|
-
export { b as Aux, f as DeploymentRelationModel, g as EdgeModel, h as LikeC4DeploymentModel, L as LikeC4Model, i as LikeC4ViewModel, N as NodeModel, R as RelationshipModel } from '../shared/core.Cpd5mZgF.js';
|
|
3
|
-
import { C as Connection, D as DeploymentConnectionModel, a as ConnectionModel } from '../shared/core.-qjOvsEL.js';
|
|
4
|
-
import { I as IterableContainer, R as ReorderedArray } from '../shared/core.CIbWBWW3.js';
|
|
5
|
-
import 'type-fest';
|
|
6
|
-
import '../shared/core.BH59D8Ji.js';
|
|
7
|
-
import '../shared/core.30yYKXcZ.js';
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* Check if connection is nested inside another connection
|
|
11
|
-
* (i.e. between descendants)
|
|
12
|
-
*/
|
|
13
|
-
declare function isNestedConnection<T extends {
|
|
14
|
-
id: string;
|
|
15
|
-
}>(parent: WithSourceTarget<NoInfer<T>>): (nested: WithSourceTarget<T>) => boolean;
|
|
16
|
-
declare function isNestedConnection<T extends {
|
|
17
|
-
id: string;
|
|
18
|
-
}>(nested: WithSourceTarget<T>, parent: WithSourceTarget<T>): boolean;
|
|
19
|
-
type ConnectionElemId = Connection<{
|
|
20
|
-
readonly id: string;
|
|
21
|
-
}, any>;
|
|
22
|
-
declare function findDeepestNestedConnection<C extends ConnectionElemId>(connections: ReadonlyArray<C>, connection: C): C | null;
|
|
23
|
-
declare function sortDeepestFirst<C extends ConnectionElemId>(connections: ReadonlyArray<C>): C[];
|
|
24
|
-
type WithBoundary = {
|
|
25
|
-
boundary: null | {
|
|
26
|
-
id: string;
|
|
27
|
-
};
|
|
28
|
-
};
|
|
29
|
-
declare function sortConnectionsByBoundaryHierarchy(sort?: 'asc' | 'desc'): <T extends WithBoundary, A extends IterableContainer<T>>(array: A) => ReorderedArray<A>;
|
|
30
|
-
declare function sortConnectionsByBoundaryHierarchy<T extends WithBoundary, A extends IterableContainer<T>>(array: A, sort?: 'asc' | 'desc'): ReorderedArray<A>;
|
|
31
|
-
/**
|
|
32
|
-
* Find connections that includes given connection (i.e between it's ancestors)
|
|
33
|
-
*/
|
|
34
|
-
declare function findAscendingConnections<C extends ConnectionElemId>(connections: ReadonlyArray<C>, connection: C): Array<C>;
|
|
35
|
-
/**
|
|
36
|
-
* Find connections that includes given connection (i.e between it's descendants)
|
|
37
|
-
*/
|
|
38
|
-
declare function findDescendantConnections<C extends ConnectionElemId>(connections: ReadonlyArray<C>, connection: C): Array<C>;
|
|
39
|
-
declare function mergeConnections<C extends Connection>(connections: ReadonlyArray<C>): C[];
|
|
40
|
-
/**
|
|
41
|
-
* Excludes the values existing in `other` array.
|
|
42
|
-
* The output maintains the same order as the input.
|
|
43
|
-
*/
|
|
44
|
-
declare function differenceConnections<C extends Connection>(source: Iterable<C>, exclude: Iterable<C>): C[];
|
|
45
|
-
type WithSourceTarget<T = unknown> = {
|
|
46
|
-
source: T;
|
|
47
|
-
target: T;
|
|
48
|
-
};
|
|
49
|
-
declare function hasSameSourceTarget<T>(a: WithSourceTarget<NoInfer<T>>): (b: WithSourceTarget<T>) => boolean;
|
|
50
|
-
declare function hasSameSourceTarget<T>(a: WithSourceTarget<T>, b: WithSourceTarget<T>): boolean;
|
|
51
|
-
declare function hasSameSource<T>(a: WithSourceTarget<NoInfer<T>>): (b: WithSourceTarget<T>) => boolean;
|
|
52
|
-
declare function hasSameSource<T>(a: WithSourceTarget<T>, b: WithSourceTarget<T>): boolean;
|
|
53
|
-
declare function hasSameTarget<T>(a: WithSourceTarget<NoInfer<T>>): (b: WithSourceTarget<T>) => boolean;
|
|
54
|
-
declare function hasSameTarget<T>(a: WithSourceTarget<T>, b: WithSourceTarget<T>): boolean;
|
|
55
|
-
type WithId<T> = {
|
|
56
|
-
id: T;
|
|
57
|
-
};
|
|
58
|
-
declare function isOutgoing<T extends string>(source: WithId<NoInfer<T>>): (a: WithSourceTarget<WithId<T>>) => boolean;
|
|
59
|
-
declare function isOutgoing<T extends string>(a: WithSourceTarget<WithId<T>>, source: WithId<T>): boolean;
|
|
60
|
-
declare function isIncoming<T extends string>(target: WithId<NoInfer<T>>): (a: WithSourceTarget<WithId<T>>) => boolean;
|
|
61
|
-
declare function isIncoming<T extends string>(a: WithSourceTarget<WithId<T>>, target: WithId<T>): boolean;
|
|
62
|
-
declare function isAnyInOut<T extends string>(source: WithId<NoInfer<T>>): (a: WithSourceTarget<WithId<T>>) => boolean;
|
|
63
|
-
declare function isAnyInOut<T extends string>(a: WithSourceTarget<WithId<T>>, source: WithId<T>): boolean;
|
|
64
|
-
|
|
65
|
-
/**
|
|
66
|
-
* Resolve connection from source to target
|
|
67
|
-
* If direction is `both`, also look for reverse connection
|
|
68
|
-
*
|
|
69
|
-
* @default direction directed
|
|
70
|
-
*/
|
|
71
|
-
declare function findConnection$1<M extends AnyAux>(source: DeploymentElementModel<M>, target: DeploymentElementModel<NoInfer<M>>, direction: 'directed'): readonly [DeploymentConnectionModel<M>] | readonly [];
|
|
72
|
-
declare function findConnection$1<M extends AnyAux>(source: DeploymentElementModel<M>, target: DeploymentElementModel<NoInfer<M>>, direction: 'both'): readonly [DeploymentConnectionModel<M>, DeploymentConnectionModel<M>] | readonly [DeploymentConnectionModel<M>] | readonly [];
|
|
73
|
-
declare function findConnection$1<M extends AnyAux>(source: DeploymentElementModel<M>, target: DeploymentElementModel<NoInfer<M>>, direction?: 'directed' | 'both'): readonly [DeploymentConnectionModel<M>, DeploymentConnectionModel<M>] | readonly [DeploymentConnectionModel<M>] | readonly [];
|
|
74
|
-
/**
|
|
75
|
-
* Resolve all connections between element and others
|
|
76
|
-
* By default, look for both directions.
|
|
77
|
-
*
|
|
78
|
-
* @default direction both
|
|
79
|
-
*/
|
|
80
|
-
declare function findConnectionsBetween$1<M extends AnyAux>(element: DeploymentElementModel<M>, others: Iterable<DeploymentElementModel<NoInfer<M>>>, direction?: 'directed' | 'both'): readonly DeploymentConnectionModel<M>[];
|
|
81
|
-
/**
|
|
82
|
-
* Resolve all connections within a given set of elements
|
|
83
|
-
*/
|
|
84
|
-
declare function findConnectionsWithin$1<M extends AnyAux>(elements: Iterable<DeploymentElementModel<M>>): readonly DeploymentConnectionModel<M>[];
|
|
85
|
-
|
|
86
|
-
declare namespace find$1 {
|
|
87
|
-
export { findConnection$1 as findConnection, findConnectionsBetween$1 as findConnectionsBetween, findConnectionsWithin$1 as findConnectionsWithin };
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
/**
|
|
91
|
-
* Resolve connection from source to target
|
|
92
|
-
*
|
|
93
|
-
* @param direction - if 'both', also returns connection from target to source
|
|
94
|
-
* @default `directed`
|
|
95
|
-
*/
|
|
96
|
-
declare function findConnection<M extends AnyAux>(source: ElementModel<M>, target: ElementModel<M>, direction?: 'directed' | 'both'): [ConnectionModel<M>, ConnectionModel<M>] | [ConnectionModel<M>] | [];
|
|
97
|
-
/**
|
|
98
|
-
* Resolve all connections between element and others
|
|
99
|
-
* @param direction - if 'directed', only look for outgoing connections from the element to others
|
|
100
|
-
* @default `both`
|
|
101
|
-
*/
|
|
102
|
-
declare function findConnectionsBetween<M extends AnyAux>(element: ElementModel<M>, others: Iterable<ElementModel<NoInfer<M>>>, direction?: 'directed' | 'both'): readonly ConnectionModel<M>[];
|
|
103
|
-
/**
|
|
104
|
-
* Resolve all connections within a given set of elements
|
|
105
|
-
*/
|
|
106
|
-
declare function findConnectionsWithin<M extends AnyAux>(elements: Iterable<ElementModel<M>>): readonly ConnectionModel<M>[];
|
|
107
|
-
|
|
108
|
-
declare const find_findConnection: typeof findConnection;
|
|
109
|
-
declare const find_findConnectionsBetween: typeof findConnectionsBetween;
|
|
110
|
-
declare const find_findConnectionsWithin: typeof findConnectionsWithin;
|
|
111
|
-
declare namespace find {
|
|
112
|
-
export { find_findConnection as findConnection, find_findConnectionsBetween as findConnectionsBetween, find_findConnectionsWithin as findConnectionsWithin };
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
declare function isDeploymentNode(model: DeploymentElementModel): model is DeploymentNodeModel;
|
|
116
|
-
declare function isDeployedInstance(model: DeploymentElementModel): model is DeployedInstanceModel;
|
|
117
|
-
|
|
118
|
-
export { AnyAux, Connection, ConnectionModel, DeployedInstanceModel, DeploymentConnectionModel, DeploymentElementModel, DeploymentNodeModel, ElementModel, find$1 as deploymentConnection, differenceConnections, findAscendingConnections, findDeepestNestedConnection, findDescendantConnections, hasSameSource, hasSameSourceTarget, hasSameTarget, isAnyInOut, isDeployedInstance, isDeploymentNode, isIncoming, isNestedConnection, isOutgoing, mergeConnections, find as modelConnection, sortConnectionsByBoundaryHierarchy, sortDeepestFirst };
|
|
@@ -1,146 +0,0 @@
|
|
|
1
|
-
import { E as ElementModel, d as DeploymentElementModel, A as AnyAux, e as DeploymentNodeModel, D as DeployedInstanceModel, j as RelationshipsAccum, R as RelationshipModel, f as DeploymentRelationModel } from './core.Cpd5mZgF.js';
|
|
2
|
-
import { F as Fqn, a as IteratorLike } from './core.30yYKXcZ.js';
|
|
3
|
-
|
|
4
|
-
interface Connection<Elem = ElementModel | DeploymentElementModel, Id = string> {
|
|
5
|
-
readonly id: Id;
|
|
6
|
-
readonly source: Elem;
|
|
7
|
-
readonly target: Elem;
|
|
8
|
-
/**
|
|
9
|
-
* Common ancestor of the source and target elements.
|
|
10
|
-
* Represents the boundary of the connection.
|
|
11
|
-
*/
|
|
12
|
-
readonly boundary: Elem | null;
|
|
13
|
-
/**
|
|
14
|
-
* Human readable expression of the connection
|
|
15
|
-
* Mostly used for testing and debugging
|
|
16
|
-
*/
|
|
17
|
-
readonly expression: string;
|
|
18
|
-
mergeWith(this: Connection<Elem, Id>, other: typeof this): typeof this;
|
|
19
|
-
nonEmpty(): boolean;
|
|
20
|
-
difference(this: Connection<Elem, Id>, other: typeof this): typeof this;
|
|
21
|
-
intersect(this: Connection<Elem, Id>, other: typeof this): typeof this;
|
|
22
|
-
equals(other: Connection): boolean;
|
|
23
|
-
}
|
|
24
|
-
declare namespace Connection {
|
|
25
|
-
type ConnectionPredicate = <C extends Connection<{
|
|
26
|
-
id: string;
|
|
27
|
-
}, any>>(connection: C) => boolean;
|
|
28
|
-
type ElementId = Fqn | string;
|
|
29
|
-
export const isInside: (fqn: ElementId) => ConnectionPredicate;
|
|
30
|
-
export const isDirectedBetween: (source: ElementId, target: ElementId) => ConnectionPredicate;
|
|
31
|
-
export const isAnyBetween: (source: ElementId, target: ElementId) => ConnectionPredicate;
|
|
32
|
-
export const isIncoming: (target: ElementId) => ConnectionPredicate;
|
|
33
|
-
export const isOutgoing: (source: ElementId) => ConnectionPredicate;
|
|
34
|
-
export const isAnyInOut: (source: ElementId) => ConnectionPredicate;
|
|
35
|
-
export { };
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
declare const customInspectSymbol: unique symbol;
|
|
39
|
-
|
|
40
|
-
/**
|
|
41
|
-
* Connection is ephemeral entity, result of a resolving relationships between source and target.
|
|
42
|
-
* Includes direct relationships and/or between their nested elements.
|
|
43
|
-
*/
|
|
44
|
-
declare class DeploymentConnectionModel<M extends AnyAux = AnyAux> implements Connection<DeploymentElementModel<M>, M['EdgeId']> {
|
|
45
|
-
readonly source: DeploymentNodeModel<M> | DeployedInstanceModel<M>;
|
|
46
|
-
readonly target: DeploymentNodeModel<M> | DeployedInstanceModel<M>;
|
|
47
|
-
readonly relations: RelationshipsAccum<M>;
|
|
48
|
-
constructor(source: DeploymentNodeModel<M> | DeployedInstanceModel<M>, target: DeploymentNodeModel<M> | DeployedInstanceModel<M>, relations: RelationshipsAccum<M>);
|
|
49
|
-
readonly id: M['EdgeId'];
|
|
50
|
-
/**
|
|
51
|
-
* Human readable expression of the connection
|
|
52
|
-
* Mostly used for testing and debugging
|
|
53
|
-
*/
|
|
54
|
-
get expression(): string;
|
|
55
|
-
private _boundary;
|
|
56
|
-
/**
|
|
57
|
-
* Common ancestor of the source and target elements.
|
|
58
|
-
* Represents the boundary of the connection.
|
|
59
|
-
*/
|
|
60
|
-
get boundary(): DeploymentNodeModel<M> | null;
|
|
61
|
-
nonEmpty(): boolean;
|
|
62
|
-
[customInspectSymbol](depth: any, inspectOptions: any, inspect: any): string;
|
|
63
|
-
toString(): string;
|
|
64
|
-
/**
|
|
65
|
-
* Check if connection contains deployment relation,
|
|
66
|
-
* that is directly connected to source or target.
|
|
67
|
-
*/
|
|
68
|
-
hasDirectDeploymentRelation(): boolean;
|
|
69
|
-
values(): IteratorLike<RelationshipModel<M> | DeploymentRelationModel<M>>;
|
|
70
|
-
/**
|
|
71
|
-
* Merge with another connections, if it has the same source and target.
|
|
72
|
-
* Returns new connection with union of relationships.
|
|
73
|
-
*/
|
|
74
|
-
mergeWith(others: DeploymentConnectionModel<M>[]): DeploymentConnectionModel<M>;
|
|
75
|
-
/**
|
|
76
|
-
* Merge with another connection, if it has the same source and target.
|
|
77
|
-
* Returns new connection with union of relationships.
|
|
78
|
-
*/
|
|
79
|
-
mergeWith(other: DeploymentConnectionModel<M>): DeploymentConnectionModel<M>;
|
|
80
|
-
difference(other: DeploymentConnectionModel<M>): DeploymentConnectionModel<M>;
|
|
81
|
-
intersect(other: DeploymentConnectionModel<M>): DeploymentConnectionModel<M>;
|
|
82
|
-
equals(other: Connection): boolean;
|
|
83
|
-
/**
|
|
84
|
-
* Creates a clone of the current `DeploymentConnectionModel` instance with optional overrides.
|
|
85
|
-
* if `null` is provided in overrides, the corresponding relation set will be empty.
|
|
86
|
-
*/
|
|
87
|
-
update(overrides?: {
|
|
88
|
-
model?: ReadonlySet<RelationshipModel<M>> | null;
|
|
89
|
-
deployment?: ReadonlySet<DeploymentRelationModel<M>> | null;
|
|
90
|
-
}): DeploymentConnectionModel<M>;
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
/**
|
|
94
|
-
* Connection refers to any relationships between two elements,
|
|
95
|
-
* both direct and implicit ones (between their nested elements).
|
|
96
|
-
*
|
|
97
|
-
* Merges relationships together to an single edge on the diagram.
|
|
98
|
-
*/
|
|
99
|
-
declare class ConnectionModel<M extends AnyAux = AnyAux> implements Connection<ElementModel<M>, M['EdgeId']> {
|
|
100
|
-
readonly source: ElementModel<M>;
|
|
101
|
-
readonly target: ElementModel<M>;
|
|
102
|
-
readonly relations: ReadonlySet<RelationshipModel<M>>;
|
|
103
|
-
readonly id: M['EdgeId'];
|
|
104
|
-
constructor(source: ElementModel<M>, target: ElementModel<M>, relations?: ReadonlySet<RelationshipModel<M>>);
|
|
105
|
-
private _boundary;
|
|
106
|
-
/**
|
|
107
|
-
* Common ancestor of the source and target elements.
|
|
108
|
-
* Represents the boundary of the connection.
|
|
109
|
-
*/
|
|
110
|
-
get boundary(): ElementModel<M> | null;
|
|
111
|
-
/**
|
|
112
|
-
* Human readable expression of the connection
|
|
113
|
-
* Mostly used for testing and debugging
|
|
114
|
-
*/
|
|
115
|
-
get expression(): string;
|
|
116
|
-
/**
|
|
117
|
-
* Returns true if only includes relations between the source and target elements.
|
|
118
|
-
*/
|
|
119
|
-
get isDirect(): boolean;
|
|
120
|
-
/**
|
|
121
|
-
* Returns true if includes relations between nested elements of the source and target elements.
|
|
122
|
-
*/
|
|
123
|
-
get isImplicit(): boolean;
|
|
124
|
-
get directRelations(): ReadonlySet<RelationshipModel<M>>;
|
|
125
|
-
nonEmpty(): boolean;
|
|
126
|
-
mergeWith(other: ConnectionModel<M>): ConnectionModel<M>;
|
|
127
|
-
difference(other: ConnectionModel<M>): ConnectionModel<M>;
|
|
128
|
-
intersect(other: ConnectionModel<M>): ConnectionModel<M>;
|
|
129
|
-
equals(other: Connection): boolean;
|
|
130
|
-
/**
|
|
131
|
-
* Returns a new instance with the updated relations.
|
|
132
|
-
*
|
|
133
|
-
* @param relations - A readonly set of `RelationshipModel` instances representing the new relations.
|
|
134
|
-
* @returns A new `ConnectionModel` instance with the updated relations.
|
|
135
|
-
*/
|
|
136
|
-
update(relations: ReadonlySet<RelationshipModel<M>>): ConnectionModel<M>;
|
|
137
|
-
[customInspectSymbol](depth: any, inspectOptions: any, inspect: any): string;
|
|
138
|
-
toString(): string;
|
|
139
|
-
/**
|
|
140
|
-
* Creates a new connection with reversed direction (target becomes source and vice versa)
|
|
141
|
-
* @param search - When true, attempts to find an existing connection between the reversed nodes
|
|
142
|
-
*/
|
|
143
|
-
reversed(search?: boolean): ConnectionModel<M>;
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
export { Connection as C, DeploymentConnectionModel as D, ConnectionModel as a };
|
|
@@ -1,186 +0,0 @@
|
|
|
1
|
-
import { LiteralUnion, Tagged, Simplify, UnionToIntersection, TupleToUnion } from 'type-fest';
|
|
2
|
-
|
|
3
|
-
declare const ThemeColors: readonly ["amber", "blue", "gray", "slate", "green", "indigo", "muted", "primary", "red", "secondary", "sky"];
|
|
4
|
-
type ThemeColor = typeof ThemeColors[number];
|
|
5
|
-
type HexColorLiteral = `#${string}`;
|
|
6
|
-
type ColorLiteral = HexColorLiteral;
|
|
7
|
-
type Color = LiteralUnion<ThemeColor, string>;
|
|
8
|
-
type ShapeSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
9
|
-
/**
|
|
10
|
-
* For padding, margin, etc.
|
|
11
|
-
*/
|
|
12
|
-
type SpacingSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
13
|
-
type TextSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
14
|
-
declare function isThemeColor(color: Color): color is ThemeColor;
|
|
15
|
-
interface ElementThemeColorValues {
|
|
16
|
-
fill: ColorLiteral;
|
|
17
|
-
stroke: ColorLiteral;
|
|
18
|
-
hiContrast: ColorLiteral;
|
|
19
|
-
loContrast: ColorLiteral;
|
|
20
|
-
}
|
|
21
|
-
type ElementThemeColors = {
|
|
22
|
-
[key in ThemeColor]: ElementThemeColorValues;
|
|
23
|
-
};
|
|
24
|
-
interface RelationshipThemeColorValues {
|
|
25
|
-
lineColor: ColorLiteral;
|
|
26
|
-
labelBgColor: ColorLiteral;
|
|
27
|
-
labelColor: ColorLiteral;
|
|
28
|
-
}
|
|
29
|
-
interface ThemeColorValues {
|
|
30
|
-
elements: ElementThemeColorValues;
|
|
31
|
-
relationships: RelationshipThemeColorValues;
|
|
32
|
-
}
|
|
33
|
-
type RelationshipThemeColors = {
|
|
34
|
-
[key in ThemeColor]: RelationshipThemeColorValues;
|
|
35
|
-
};
|
|
36
|
-
interface LikeC4Theme {
|
|
37
|
-
font: 'Arial';
|
|
38
|
-
shadow: ColorLiteral;
|
|
39
|
-
relationships: RelationshipThemeColors;
|
|
40
|
-
elements: ElementThemeColors;
|
|
41
|
-
sizes: {
|
|
42
|
-
[key in ShapeSize]: {
|
|
43
|
-
width: number;
|
|
44
|
-
height: number;
|
|
45
|
-
};
|
|
46
|
-
};
|
|
47
|
-
spacing: {
|
|
48
|
-
[key in SpacingSize]: number;
|
|
49
|
-
};
|
|
50
|
-
textSizes: {
|
|
51
|
-
[key in TextSize]: number;
|
|
52
|
-
};
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
type ProjectId = Tagged<string, 'ProjectID'>;
|
|
56
|
-
type NonEmptyArray<T> = [T, ...T[]];
|
|
57
|
-
type NonEmptyReadonlyArray<T> = readonly [T, ...T[]];
|
|
58
|
-
type IconUrl = Tagged<string, 'IconUrl'> | 'none';
|
|
59
|
-
type CustomColor = string;
|
|
60
|
-
type Point = readonly [x: number, y: number];
|
|
61
|
-
interface XYPoint {
|
|
62
|
-
x: number;
|
|
63
|
-
y: number;
|
|
64
|
-
}
|
|
65
|
-
type KeysOf<T> = keyof T extends infer K extends string ? K : never;
|
|
66
|
-
type AllNever<Expressions> = UnionToIntersection<{
|
|
67
|
-
[Name in keyof Expressions]: {
|
|
68
|
-
-readonly [Key in keyof Expressions[Name]]?: never;
|
|
69
|
-
};
|
|
70
|
-
}[keyof Expressions]>;
|
|
71
|
-
/**
|
|
72
|
-
* @example
|
|
73
|
-
* type Variant1 = {
|
|
74
|
-
* a: string
|
|
75
|
-
* }
|
|
76
|
-
* type Variant2 = {
|
|
77
|
-
* b: number
|
|
78
|
-
* }
|
|
79
|
-
*
|
|
80
|
-
* type Variants = ExclusiveUnion<{
|
|
81
|
-
* Variant1: Variant1,
|
|
82
|
-
* Variant2: Variant2
|
|
83
|
-
* }>
|
|
84
|
-
*
|
|
85
|
-
* Fail here
|
|
86
|
-
* const variant1: Variants = {
|
|
87
|
-
* a: 'one',
|
|
88
|
-
* b: 1
|
|
89
|
-
* }
|
|
90
|
-
*/
|
|
91
|
-
type ExclusiveUnion<Expressions> = Expressions extends object ? {
|
|
92
|
-
[Name in keyof Expressions]: Simplify<Omit<AllNever<Expressions>, keyof Expressions[Name]> & Expressions[Name]>;
|
|
93
|
-
}[keyof Expressions] : Expressions;
|
|
94
|
-
/**
|
|
95
|
-
* Copy from https://github.com/remeda/remeda/blob/main/src/internal/types/NTuple.ts
|
|
96
|
-
* An array with *exactly* N elements in it.
|
|
97
|
-
*
|
|
98
|
-
* Only literal N values are supported. For very large N the type might result
|
|
99
|
-
* in a recurse depth error. For negative N the type would result in an infinite
|
|
100
|
-
* recursion. None of these have protections because this is an internal type!
|
|
101
|
-
*/
|
|
102
|
-
type NTuple<T, N extends number, Result extends Array<unknown> = []> = Result['length'] extends N ? Result : NTuple<T, N, [...Result, T]>;
|
|
103
|
-
type IteratorLike<T> = IteratorObject<T, BuiltinIteratorReturn>;
|
|
104
|
-
type Predicate<T> = (x: T) => boolean;
|
|
105
|
-
|
|
106
|
-
type Fqn<Id extends string = string> = Tagged<Id, 'Fqn'>;
|
|
107
|
-
declare function AsFqn(name: string, parent?: Fqn | null): Fqn;
|
|
108
|
-
declare const BorderStyles: readonly ["solid", "dashed", "dotted", "none"];
|
|
109
|
-
type BorderStyle = TupleToUnion<typeof BorderStyles>;
|
|
110
|
-
type ElementKind<Kinds extends string = string> = Tagged<Kinds, 'ElementKind'>;
|
|
111
|
-
declare namespace ElementKind {
|
|
112
|
-
const Group: ElementKind;
|
|
113
|
-
}
|
|
114
|
-
declare const ElementShapes: readonly ["rectangle", "person", "browser", "mobile", "cylinder", "storage", "queue"];
|
|
115
|
-
type ElementShape = TupleToUnion<typeof ElementShapes>;
|
|
116
|
-
declare const DefaultThemeColor: ThemeColor;
|
|
117
|
-
declare const DefaultElementShape: ElementShape;
|
|
118
|
-
declare const DefaultShapeSize: ShapeSize;
|
|
119
|
-
declare const DefaultPaddingSize: SpacingSize;
|
|
120
|
-
declare const DefaultTextSize: TextSize;
|
|
121
|
-
interface ElementStyle {
|
|
122
|
-
readonly border?: BorderStyle;
|
|
123
|
-
/**
|
|
124
|
-
* In percentage 0-100, 0 is fully transparent
|
|
125
|
-
*
|
|
126
|
-
* @default 100
|
|
127
|
-
*/
|
|
128
|
-
readonly opacity?: number;
|
|
129
|
-
/**
|
|
130
|
-
* If true, the element is rendered as multiple shapes
|
|
131
|
-
* @default false
|
|
132
|
-
*/
|
|
133
|
-
readonly multiple?: boolean;
|
|
134
|
-
/**
|
|
135
|
-
* Shape size
|
|
136
|
-
*
|
|
137
|
-
* @default 'md'
|
|
138
|
-
*/
|
|
139
|
-
readonly size?: ShapeSize;
|
|
140
|
-
readonly padding?: SpacingSize;
|
|
141
|
-
readonly textSize?: TextSize;
|
|
142
|
-
}
|
|
143
|
-
type Tag<Tags extends string = string> = Tagged<Tags, 'Tag'>;
|
|
144
|
-
interface TagSpec {
|
|
145
|
-
readonly id: Tag;
|
|
146
|
-
readonly style: ElementStyle;
|
|
147
|
-
}
|
|
148
|
-
interface Link {
|
|
149
|
-
readonly title?: string;
|
|
150
|
-
readonly url: string;
|
|
151
|
-
readonly relative?: string;
|
|
152
|
-
}
|
|
153
|
-
interface TypedElement<Ids extends string, Kinds extends string, Tags extends string, MetadataKeys extends string = never> {
|
|
154
|
-
readonly id: Fqn<Ids>;
|
|
155
|
-
readonly kind: ElementKind<Kinds>;
|
|
156
|
-
readonly title: string;
|
|
157
|
-
readonly description: string | null;
|
|
158
|
-
readonly technology: string | null;
|
|
159
|
-
readonly tags: NonEmptyArray<Tag<Tags>> | null;
|
|
160
|
-
readonly links: NonEmptyArray<Link> | null;
|
|
161
|
-
readonly icon?: IconUrl;
|
|
162
|
-
readonly shape?: ElementShape;
|
|
163
|
-
readonly color?: Color;
|
|
164
|
-
readonly style?: ElementStyle;
|
|
165
|
-
readonly notation?: string;
|
|
166
|
-
readonly metadata?: Record<MetadataKeys, string>;
|
|
167
|
-
}
|
|
168
|
-
interface Element extends TypedElement<string, string, string, string> {
|
|
169
|
-
}
|
|
170
|
-
interface ElementKindSpecificationStyle {
|
|
171
|
-
shape?: ElementShape;
|
|
172
|
-
icon?: IconUrl;
|
|
173
|
-
color?: Color;
|
|
174
|
-
border?: BorderStyle;
|
|
175
|
-
opacity?: number;
|
|
176
|
-
size?: ShapeSize;
|
|
177
|
-
padding?: SpacingSize;
|
|
178
|
-
textSize?: TextSize;
|
|
179
|
-
}
|
|
180
|
-
interface ElementKindSpecification {
|
|
181
|
-
readonly technology?: string;
|
|
182
|
-
readonly notation?: string;
|
|
183
|
-
readonly style: ElementKindSpecificationStyle;
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
export { AsFqn as A, BorderStyles as B, type CustomColor as C, DefaultElementShape as D, type ExclusiveUnion as E, type Fqn as F, type ElementThemeColorValues as G, type HexColorLiteral as H, type IconUrl as I, type RelationshipThemeColorValues as J, type KeysOf as K, type LikeC4Theme as L, type SpacingSize as M, type NonEmptyArray as N, type TextSize as O, type Point as P, type ThemeColor as Q, type RelationshipThemeColors as R, type ShapeSize as S, type ThemeColorValues as T, type XYPoint as X, type IteratorLike as a, type NonEmptyReadonlyArray as b, type NTuple as c, type Predicate as d, type ProjectId as e, DefaultPaddingSize as f, DefaultShapeSize as g, DefaultTextSize as h, DefaultThemeColor as i, ElementKind as j, ElementShapes as k, type BorderStyle as l, type Element as m, type ElementKindSpecification as n, type ElementKindSpecificationStyle as o, type ElementShape as p, type ElementStyle as q, type Link as r, type Tag as s, type TagSpec as t, type TypedElement as u, isThemeColor as v, ThemeColors as w, type Color as x, type ColorLiteral as y, type ElementThemeColors as z };
|