@likec4/core 1.20.0 → 1.20.2
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.cjs +6 -6
- package/dist/builder/index.d.cts +3 -3
- package/dist/builder/index.d.mts +3 -3
- package/dist/builder/index.d.ts +3 -3
- package/dist/builder/index.mjs +6 -6
- package/dist/compute-view/index.cjs +5 -5
- package/dist/compute-view/index.d.cts +4 -4
- package/dist/compute-view/index.d.mts +4 -4
- package/dist/compute-view/index.d.ts +4 -4
- package/dist/compute-view/index.mjs +6 -6
- package/dist/index.cjs +71 -573
- package/dist/index.d.cts +9 -133
- package/dist/index.d.mts +9 -133
- package/dist/index.d.ts +9 -133
- package/dist/index.mjs +8 -512
- package/dist/model/index.cjs +1 -1
- package/dist/model/index.d.cts +5 -5
- package/dist/model/index.d.mts +5 -5
- package/dist/model/index.d.ts +5 -5
- package/dist/model/index.mjs +1 -1
- package/dist/shared/{core.DunIMHRf.mjs → core.0PxLtLpP.mjs} +1 -1
- package/dist/shared/{core.BvdNMbcA.d.cts → core.88YY6vtF.d.mts} +2 -2
- package/dist/shared/{core.ByNgh-mC.d.cts → core.BIZD3l1g.d.cts} +1 -1
- package/dist/shared/{core.D74xkKkG.d.ts → core.BJfn72tj.d.cts} +5 -0
- package/dist/shared/{core.D74xkKkG.d.cts → core.BJfn72tj.d.mts} +5 -0
- package/dist/shared/{core.D74xkKkG.d.mts → core.BJfn72tj.d.ts} +5 -0
- package/dist/shared/{core.M-JWF7SS.mjs → core.Bezy7K65.mjs} +1 -1
- package/dist/shared/{core.D_Gc58Gt.d.ts → core.Bs71hdR4.d.ts} +2 -1
- package/dist/shared/{core.D6-fWbM3.d.ts → core.BtISRjMA.d.ts} +1 -1
- package/dist/shared/{core.B72vUaNB.d.cts → core.C0ygs98j.d.cts} +2 -1
- package/dist/shared/core.CCyhaU-4.mjs +14819 -0
- package/dist/shared/{core.DsoCu540.cjs → core.CKYxnFEl.cjs} +1 -1
- package/dist/shared/{core.Damrzla-.d.ts → core.CNUzoKM7.d.ts} +2 -2
- package/dist/shared/{core.sLaWHBjR.d.mts → core.CajOK_t3.d.mts} +1 -1
- package/dist/shared/{core.BdbFkE_p.d.cts → core.Cmfo_N4F.d.mts} +3 -3
- package/dist/shared/{core.jy6z2iRn.d.mts → core.CwZmAghJ.d.cts} +3 -3
- package/dist/shared/{core.ZWiGANIJ.d.ts → core.D4wZW7zR.d.ts} +3 -3
- package/dist/shared/{core.gv1bMwCC.cjs → core.Db_OTRdC.cjs} +1 -1
- package/dist/shared/{core.Dfzrh1VA.d.mts → core.DjMYkPMQ.d.mts} +2 -1
- package/dist/shared/{core.BGus30EM.cjs → core.DxJ1KbOs.cjs} +48 -643
- package/dist/shared/{core.m3rCQAv6.mjs → core.El-gigOM.mjs} +1 -1
- package/dist/shared/core.FACQZmma.cjs +14874 -0
- package/dist/shared/{core.BRuJ3Wzf.d.mts → core.Lh2RFJf1.d.cts} +2 -2
- package/dist/shared/{core.CqCTxzMY.mjs → core.PYycpzvA.mjs} +28 -619
- package/dist/shared/{core.B2QYWlYe.cjs → core.uxHtIZaH.cjs} +1 -1
- package/dist/types/index.cjs +1 -1
- package/dist/types/index.d.cts +4 -4
- package/dist/types/index.d.mts +4 -4
- package/dist/types/index.d.ts +4 -4
- package/dist/types/index.mjs +1 -1
- package/dist/utils/index.cjs +6 -2
- package/dist/utils/index.d.cts +129 -145
- package/dist/utils/index.d.mts +129 -145
- package/dist/utils/index.d.ts +129 -145
- package/dist/utils/index.mjs +3 -3
- package/package.json +7 -6
- package/src/compute-view/deployment-view/clean-connections.ts +1 -1
- package/src/compute-view/deployment-view/stages/stage-final.ts +1 -1
- package/src/compute-view/element-view/__test__/fixture.ts +2 -0
- package/src/compute-view/element-view/compute.ts +1 -1
- package/src/compute-view/element-view/memory/memory.ts +2 -2
- package/src/compute-view/memory/ops.ts +1 -1
- package/src/compute-view/relationships-view/layout.ts +1 -1
- package/src/compute-view/relationships-view/utils.ts +1 -1
- package/src/compute-view/utils/applyCustomElementProperties.ts +9 -6
- package/src/compute-view/utils/applyViewRuleStyles.ts +7 -4
- package/src/index.ts +0 -8
- package/src/model/DeploymentModel.ts +1 -1
- package/src/model/LikeC4Model.ts +3 -3
- package/src/types/element.ts +7 -2
- package/src/types/expression.ts +1 -0
- package/src/utils/index.ts +2 -0
- package/src/utils/set.ts +5 -2
- package/dist/shared/core.BxvDITEI.mjs +0 -859
- package/dist/shared/core.C9DCnJh8.cjs +0 -908
- package/src/builder/Builder-style1.test-d.ts +0 -190
- package/src/builder/Builder-style2.test-d.ts +0 -175
- package/src/compute-view/utils/uniqueTags.test.ts +0 -42
- package/src/model/LikeC4Model.test-d.ts +0 -152
package/dist/builder/index.cjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const model_index = require('../shared/core.
|
|
4
|
-
const object_hash = require('../shared/core.
|
|
5
|
-
const view = require('../shared/core.
|
|
6
|
-
const chunkRAAYCPUM = require('../shared/core.
|
|
3
|
+
const model_index = require('../shared/core.DxJ1KbOs.cjs');
|
|
4
|
+
const object_hash = require('../shared/core.FACQZmma.cjs');
|
|
5
|
+
const view = require('../shared/core.uxHtIZaH.cjs');
|
|
6
|
+
const chunkRAAYCPUM = require('../shared/core.CKYxnFEl.cjs');
|
|
7
7
|
|
|
8
8
|
function n(...r){return chunkRAAYCPUM.u(Object.fromEntries,r)}
|
|
9
9
|
|
|
@@ -34,7 +34,7 @@ function _defu(baseObject, defaults, namespace = ".", merger) {
|
|
|
34
34
|
continue;
|
|
35
35
|
}
|
|
36
36
|
const value = baseObject[key];
|
|
37
|
-
if (value === null || value ===
|
|
37
|
+
if (value === null || value === undefined) {
|
|
38
38
|
continue;
|
|
39
39
|
}
|
|
40
40
|
if (merger && merger(object, key, value, namespace)) {
|
|
@@ -126,7 +126,7 @@ function $include(...args) {
|
|
|
126
126
|
return (b) => {
|
|
127
127
|
let expr = b.$expr(args[0]);
|
|
128
128
|
if (args.length === 2) {
|
|
129
|
-
const condition = args[1].where ? parseWhere(args[1].where) :
|
|
129
|
+
const condition = args[1].where ? parseWhere(args[1].where) : undefined;
|
|
130
130
|
if (condition) {
|
|
131
131
|
expr = {
|
|
132
132
|
where: {
|
package/dist/builder/index.d.cts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { LastArrayElement, Split, Simplify, Writable, IfNever, Tagged, IsLiteral, IsStringLiteral as IsStringLiteral$1, TupleToUnion } from 'type-fest';
|
|
2
|
-
import { L as LikeC4Model } from '../shared/core.
|
|
3
|
-
import { D as DeploymentElement, i as DeploymentRelation, at as ModelRelation, bs as ViewRuleStyle, aT as AutoLayoutDirection, bx as Participant, A as CustomElementExpr, B as CustomRelationExpr, X as ExpressionV2, N as Expression, L as LikeC4View, b0 as DeploymentView, bd as ElementView, ax as RelationshipKindSpecification, g as DeploymentNodeKindSpecification, av as RelationshipArrowType, ay as RelationshipLineType, a9 as ParsedLikeC4Model } from '../shared/core.
|
|
4
|
-
import { F as Fqn, i as Element, N as NonEmptyArray, j as ElementKindSpecification, l as ElementShape, s as Color, h as BorderStyle, K as KeysOf } from '../shared/core.
|
|
2
|
+
import { L as LikeC4Model } from '../shared/core.CwZmAghJ.cjs';
|
|
3
|
+
import { D as DeploymentElement, i as DeploymentRelation, at as ModelRelation, bs as ViewRuleStyle, aT as AutoLayoutDirection, bx as Participant, A as CustomElementExpr, B as CustomRelationExpr, X as ExpressionV2, N as Expression, L as LikeC4View, b0 as DeploymentView, bd as ElementView, ax as RelationshipKindSpecification, g as DeploymentNodeKindSpecification, av as RelationshipArrowType, ay as RelationshipLineType, a9 as ParsedLikeC4Model } from '../shared/core.C0ygs98j.cjs';
|
|
4
|
+
import { F as Fqn, i as Element, N as NonEmptyArray, j as ElementKindSpecification, l as ElementShape, s as Color, h as BorderStyle, K as KeysOf } from '../shared/core.BJfn72tj.cjs';
|
|
5
5
|
import { IsStringLiteral } from 'type-fest/source/is-literal';
|
|
6
6
|
|
|
7
7
|
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.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { LastArrayElement, Split, Simplify, Writable, IfNever, Tagged, IsLiteral, IsStringLiteral as IsStringLiteral$1, TupleToUnion } from 'type-fest';
|
|
2
|
-
import { L as LikeC4Model } from '../shared/core.
|
|
3
|
-
import { D as DeploymentElement, i as DeploymentRelation, at as ModelRelation, bs as ViewRuleStyle, aT as AutoLayoutDirection, bx as Participant, A as CustomElementExpr, B as CustomRelationExpr, X as ExpressionV2, N as Expression, L as LikeC4View, b0 as DeploymentView, bd as ElementView, ax as RelationshipKindSpecification, g as DeploymentNodeKindSpecification, av as RelationshipArrowType, ay as RelationshipLineType, a9 as ParsedLikeC4Model } from '../shared/core.
|
|
4
|
-
import { F as Fqn, i as Element, N as NonEmptyArray, j as ElementKindSpecification, l as ElementShape, s as Color, h as BorderStyle, K as KeysOf } from '../shared/core.
|
|
2
|
+
import { L as LikeC4Model } from '../shared/core.Cmfo_N4F.mjs';
|
|
3
|
+
import { D as DeploymentElement, i as DeploymentRelation, at as ModelRelation, bs as ViewRuleStyle, aT as AutoLayoutDirection, bx as Participant, A as CustomElementExpr, B as CustomRelationExpr, X as ExpressionV2, N as Expression, L as LikeC4View, b0 as DeploymentView, bd as ElementView, ax as RelationshipKindSpecification, g as DeploymentNodeKindSpecification, av as RelationshipArrowType, ay as RelationshipLineType, a9 as ParsedLikeC4Model } from '../shared/core.DjMYkPMQ.mjs';
|
|
4
|
+
import { F as Fqn, i as Element, N as NonEmptyArray, j as ElementKindSpecification, l as ElementShape, s as Color, h as BorderStyle, K as KeysOf } from '../shared/core.BJfn72tj.mjs';
|
|
5
5
|
import { IsStringLiteral } from 'type-fest/source/is-literal';
|
|
6
6
|
|
|
7
7
|
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.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { LastArrayElement, Split, Simplify, Writable, IfNever, Tagged, IsLiteral, IsStringLiteral as IsStringLiteral$1, TupleToUnion } from 'type-fest';
|
|
2
|
-
import { L as LikeC4Model } from '../shared/core.
|
|
3
|
-
import { D as DeploymentElement, i as DeploymentRelation, at as ModelRelation, bs as ViewRuleStyle, aT as AutoLayoutDirection, bx as Participant, A as CustomElementExpr, B as CustomRelationExpr, X as ExpressionV2, N as Expression, L as LikeC4View, b0 as DeploymentView, bd as ElementView, ax as RelationshipKindSpecification, g as DeploymentNodeKindSpecification, av as RelationshipArrowType, ay as RelationshipLineType, a9 as ParsedLikeC4Model } from '../shared/core.
|
|
4
|
-
import { F as Fqn, i as Element, N as NonEmptyArray, j as ElementKindSpecification, l as ElementShape, s as Color, h as BorderStyle, K as KeysOf } from '../shared/core.
|
|
2
|
+
import { L as LikeC4Model } from '../shared/core.D4wZW7zR.js';
|
|
3
|
+
import { D as DeploymentElement, i as DeploymentRelation, at as ModelRelation, bs as ViewRuleStyle, aT as AutoLayoutDirection, bx as Participant, A as CustomElementExpr, B as CustomRelationExpr, X as ExpressionV2, N as Expression, L as LikeC4View, b0 as DeploymentView, bd as ElementView, ax as RelationshipKindSpecification, g as DeploymentNodeKindSpecification, av as RelationshipArrowType, ay as RelationshipLineType, a9 as ParsedLikeC4Model } from '../shared/core.Bs71hdR4.js';
|
|
4
|
+
import { F as Fqn, i as Element, N as NonEmptyArray, j as ElementKindSpecification, l as ElementShape, s as Color, h as BorderStyle, K as KeysOf } from '../shared/core.BJfn72tj.js';
|
|
5
5
|
import { IsStringLiteral } from 'type-fest/source/is-literal';
|
|
6
6
|
|
|
7
7
|
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,7 +1,7 @@
|
|
|
1
|
-
import { l, L as LikeC4Model, i, d } from '../shared/core.
|
|
2
|
-
import { b as t, m, p as parentFqn, c as isSameHierarchy, n as nameFromFqn, a as i$1, l as l$1, d as t$1 } from '../shared/core.
|
|
3
|
-
import { b as isElementPredicateExpr, o, c as isScopedElementView, D as DeploymentElement, n as n$1, d as DefaultThemeColor, e as DefaultElementShape } from '../shared/core.
|
|
4
|
-
import { u, i as invariant } from '../shared/core.
|
|
1
|
+
import { l, L as LikeC4Model, i, d } from '../shared/core.PYycpzvA.mjs';
|
|
2
|
+
import { b as t, m, p as parentFqn, c as isSameHierarchy, n as nameFromFqn, a as i$1, l as l$1, d as t$1 } from '../shared/core.CCyhaU-4.mjs';
|
|
3
|
+
import { b as isElementPredicateExpr, o, c as isScopedElementView, D as DeploymentElement, n as n$1, d as DefaultThemeColor, e as DefaultElementShape } from '../shared/core.0PxLtLpP.mjs';
|
|
4
|
+
import { u, i as invariant } from '../shared/core.Bezy7K65.mjs';
|
|
5
5
|
|
|
6
6
|
function n(...r){return u(Object.fromEntries,r)}
|
|
7
7
|
|
|
@@ -32,7 +32,7 @@ function _defu(baseObject, defaults, namespace = ".", merger) {
|
|
|
32
32
|
continue;
|
|
33
33
|
}
|
|
34
34
|
const value = baseObject[key];
|
|
35
|
-
if (value === null || value ===
|
|
35
|
+
if (value === null || value === undefined) {
|
|
36
36
|
continue;
|
|
37
37
|
}
|
|
38
38
|
if (merger && merger(object, key, value, namespace)) {
|
|
@@ -124,7 +124,7 @@ function $include(...args) {
|
|
|
124
124
|
return (b) => {
|
|
125
125
|
let expr = b.$expr(args[0]);
|
|
126
126
|
if (args.length === 2) {
|
|
127
|
-
const condition = args[1].where ? parseWhere(args[1].where) :
|
|
127
|
+
const condition = args[1].where ? parseWhere(args[1].where) : undefined;
|
|
128
128
|
if (condition) {
|
|
129
129
|
expr = {
|
|
130
130
|
where: {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const model_index = require('../shared/core.
|
|
4
|
-
const compute = require('../shared/core.
|
|
5
|
-
const view = require('../shared/core.
|
|
6
|
-
const object_hash = require('../shared/core.
|
|
7
|
-
const chunkRAAYCPUM = require('../shared/core.
|
|
3
|
+
const model_index = require('../shared/core.DxJ1KbOs.cjs');
|
|
4
|
+
const compute = require('../shared/core.Db_OTRdC.cjs');
|
|
5
|
+
const view = require('../shared/core.uxHtIZaH.cjs');
|
|
6
|
+
const object_hash = require('../shared/core.FACQZmma.cjs');
|
|
7
|
+
const chunkRAAYCPUM = require('../shared/core.CKYxnFEl.cjs');
|
|
8
8
|
|
|
9
9
|
function y(...t){return chunkRAAYCPUM.u(f,t)}function f(t,e){if(!object_hash.i(e,1))return {...t};if(!object_hash.i(e,2)){let{[e[0]]:r,...m}=t;return m}let o={...t};for(let r of e)delete o[r];return o}
|
|
10
10
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { C as ComputeViewResult, c as computeView, a as computeViews, u as unsafeComputeView } from '../shared/core.
|
|
2
|
-
export { c as computeRelationshipsView } from '../shared/core.
|
|
3
|
-
import { L as LikeC4View, C as ComputedView, a as ComputedLikeC4Model } from '../shared/core.
|
|
1
|
+
export { C as ComputeViewResult, c as computeView, a as computeViews, u as unsafeComputeView } from '../shared/core.CwZmAghJ.cjs';
|
|
2
|
+
export { c as computeRelationshipsView } from '../shared/core.Lh2RFJf1.cjs';
|
|
3
|
+
import { L as LikeC4View, C as ComputedView, a as ComputedLikeC4Model } from '../shared/core.C0ygs98j.cjs';
|
|
4
4
|
import 'type-fest';
|
|
5
|
-
import '../shared/core.
|
|
5
|
+
import '../shared/core.BJfn72tj.cjs';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Resolve rules of extended views
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { C as ComputeViewResult, c as computeView, a as computeViews, u as unsafeComputeView } from '../shared/core.
|
|
2
|
-
export { c as computeRelationshipsView } from '../shared/core.
|
|
3
|
-
import { L as LikeC4View, C as ComputedView, a as ComputedLikeC4Model } from '../shared/core.
|
|
1
|
+
export { C as ComputeViewResult, c as computeView, a as computeViews, u as unsafeComputeView } from '../shared/core.Cmfo_N4F.mjs';
|
|
2
|
+
export { c as computeRelationshipsView } from '../shared/core.88YY6vtF.mjs';
|
|
3
|
+
import { L as LikeC4View, C as ComputedView, a as ComputedLikeC4Model } from '../shared/core.DjMYkPMQ.mjs';
|
|
4
4
|
import 'type-fest';
|
|
5
|
-
import '../shared/core.
|
|
5
|
+
import '../shared/core.BJfn72tj.mjs';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Resolve rules of extended views
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { C as ComputeViewResult, c as computeView, a as computeViews, u as unsafeComputeView } from '../shared/core.
|
|
2
|
-
export { c as computeRelationshipsView } from '../shared/core.
|
|
3
|
-
import { L as LikeC4View, C as ComputedView, a as ComputedLikeC4Model } from '../shared/core.
|
|
1
|
+
export { C as ComputeViewResult, c as computeView, a as computeViews, u as unsafeComputeView } from '../shared/core.D4wZW7zR.js';
|
|
2
|
+
export { c as computeRelationshipsView } from '../shared/core.CNUzoKM7.js';
|
|
3
|
+
import { L as LikeC4View, C as ComputedView, a as ComputedLikeC4Model } from '../shared/core.Bs71hdR4.js';
|
|
4
4
|
import 'type-fest';
|
|
5
|
-
import '../shared/core.
|
|
5
|
+
import '../shared/core.BJfn72tj.js';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Resolve rules of extended views
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { G as Graph, r, w as willCreateCycle, t as topologicalSortExports, l, i as i$1 } from '../shared/core.
|
|
2
|
-
export { c as computeView, a as computeViews, u as unsafeComputeView } from '../shared/core.
|
|
3
|
-
export { c as computeRelationshipsView } from '../shared/core.
|
|
4
|
-
import { i as isExtendsElementView, a as isElementView } from '../shared/core.
|
|
5
|
-
import { a as i, m } from '../shared/core.
|
|
6
|
-
import { u } from '../shared/core.
|
|
1
|
+
import { G as Graph, r, w as willCreateCycle, t as topologicalSortExports, l, i as i$1 } from '../shared/core.PYycpzvA.mjs';
|
|
2
|
+
export { c as computeView, a as computeViews, u as unsafeComputeView } from '../shared/core.PYycpzvA.mjs';
|
|
3
|
+
export { c as computeRelationshipsView } from '../shared/core.El-gigOM.mjs';
|
|
4
|
+
import { i as isExtendsElementView, a as isElementView } from '../shared/core.0PxLtLpP.mjs';
|
|
5
|
+
import { a as i, m } from '../shared/core.CCyhaU-4.mjs';
|
|
6
|
+
import { u } from '../shared/core.Bezy7K65.mjs';
|
|
7
7
|
|
|
8
8
|
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}
|
|
9
9
|
|