@elyx-code/project-logic-tree 0.0.6115 → 0.0.6116

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/index.js CHANGED
@@ -48960,51 +48960,6 @@ class ho {
48960
48960
  }
48961
48961
  class Bq {
48962
48962
  }
48963
- class bT {
48964
- constructor(e, t = "hirarchy") {
48965
- d(this, "order", []);
48966
- d(this, "flatRecord", {});
48967
- this.strategy = t, this.flatten(e), this.orderEntities();
48968
- }
48969
- flatten(e) {
48970
- const t = new Set(lT), n = f(
48971
- O(e, t, {
48972
- ignoreBuiltInBaseEntities: !0
48973
- })
48974
- ), i = /* @__PURE__ */ new Set();
48975
- for (const s of n)
48976
- this.flatRecord[s.id] = s, i.add(s.id);
48977
- this.order = Array.from(i);
48978
- }
48979
- moveEntityAfterDependencies(e) {
48980
- const t = s7(e, this.flatRecord);
48981
- for (const n of t) {
48982
- const i = this.order.indexOf(n), s = this.order.indexOf(e.id);
48983
- if (i > s)
48984
- return this.order.splice(s, 1), this.order.splice(i, 0, e.id), !0;
48985
- }
48986
- return !1;
48987
- }
48988
- orderEntities() {
48989
- let e = !1;
48990
- for (let t = 0; t < this.order.length; t++) {
48991
- const n = this.order[t], i = this.flatRecord[n];
48992
- if (this.moveEntityAfterDependencies(i)) {
48993
- e = !0;
48994
- break;
48995
- }
48996
- }
48997
- e && this.orderEntities();
48998
- }
48999
- visitEntities(e) {
49000
- const t = this.strategy === "reverse-hirarchy" ? this.order.slice().reverse() : this.order;
49001
- for (const n of t)
49002
- e(this.flatRecord[n]);
49003
- }
49004
- visit(e) {
49005
- return this.visitEntities(e), this;
49006
- }
49007
- }
49008
48963
  const Q = class Q {
49009
48964
  constructor(e) {
49010
48965
  d(this, "initialData");
@@ -49636,29 +49591,7 @@ const Q = class Q {
49636
49591
  return this.errors;
49637
49592
  }
49638
49593
  clone() {
49639
- const e = /* @__PURE__ */ new Map(), t = this.getAllBuiltInIds();
49640
- Object.keys(this.instances).forEach((i) => {
49641
- if (t.includes(i)) {
49642
- e.set(i, i);
49643
- return;
49644
- }
49645
- e.set(i, Q.UUID.uuid());
49646
- });
49647
- const n = vT(
49648
- this.toShallowJSON({ seenEntityMaps: e })
49649
- );
49650
- return new bT(this).visit((i) => {
49651
- const s = v(
49652
- i.toShallowJSON({ seenEntityMaps: e }),
49653
- n
49654
- );
49655
- s.hydrateAncestors(), s.addSelfToProject();
49656
- }).visit((i) => {
49657
- const s = n.get(
49658
- e.get(i.id)
49659
- );
49660
- s && s.afterAllChildrenInitialized();
49661
- }), n.afterAllChildrenInitialized(), n;
49594
+ return this;
49662
49595
  }
49663
49596
  getCustomEntity(e) {
49664
49597
  return this.entities.find((t) => t.id === e) || null;
@@ -50686,6 +50619,51 @@ function k7(r) {
50686
50619
  t.initChildren(), r.subscribeBuiltInInstance(t);
50687
50620
  }), r.operationDeclarations = e, e;
50688
50621
  }
50622
+ class bT {
50623
+ constructor(e, t = "hirarchy") {
50624
+ d(this, "order", []);
50625
+ d(this, "flatRecord", {});
50626
+ this.strategy = t, this.flatten(e), this.orderEntities();
50627
+ }
50628
+ flatten(e) {
50629
+ const t = new Set(lT), n = f(
50630
+ O(e, t, {
50631
+ ignoreBuiltInBaseEntities: !0
50632
+ })
50633
+ ), i = /* @__PURE__ */ new Set();
50634
+ for (const s of n)
50635
+ this.flatRecord[s.id] = s, i.add(s.id);
50636
+ this.order = Array.from(i);
50637
+ }
50638
+ moveEntityAfterDependencies(e) {
50639
+ const t = s7(e, this.flatRecord);
50640
+ for (const n of t) {
50641
+ const i = this.order.indexOf(n), s = this.order.indexOf(e.id);
50642
+ if (i > s)
50643
+ return this.order.splice(s, 1), this.order.splice(i, 0, e.id), !0;
50644
+ }
50645
+ return !1;
50646
+ }
50647
+ orderEntities() {
50648
+ let e = !1;
50649
+ for (let t = 0; t < this.order.length; t++) {
50650
+ const n = this.order[t], i = this.flatRecord[n];
50651
+ if (this.moveEntityAfterDependencies(i)) {
50652
+ e = !0;
50653
+ break;
50654
+ }
50655
+ }
50656
+ e && this.orderEntities();
50657
+ }
50658
+ visitEntities(e) {
50659
+ const t = this.strategy === "reverse-hirarchy" ? this.order.slice().reverse() : this.order;
50660
+ for (const n of t)
50661
+ e(this.flatRecord[n]);
50662
+ }
50663
+ visit(e) {
50664
+ return this.visitEntities(e), this;
50665
+ }
50666
+ }
50689
50667
  const xr = {}, qi = {};
50690
50668
  async function J7(r, e = {}) {
50691
50669
  const t = {
@@ -50718,6 +50696,33 @@ function vT(r) {
50718
50696
  e.builtInInstances[n.id] || (e.builtInInstances[n.id] = n, delete e.instances[n.id]);
50719
50697
  }), e;
50720
50698
  }
50699
+ function Mq(r) {
50700
+ const e = /* @__PURE__ */ new Map(), t = r.getAllBuiltInIds();
50701
+ Object.keys(r.instances).forEach((i) => {
50702
+ if (t.includes(i)) {
50703
+ e.set(i, i);
50704
+ return;
50705
+ }
50706
+ e.set(i, B.UUID.uuid());
50707
+ });
50708
+ const n = vT(
50709
+ r.toShallowJSON({ seenEntityMaps: e })
50710
+ );
50711
+ return new bT(r).visit((i) => {
50712
+ const s = v(
50713
+ i.toShallowJSON({
50714
+ seenEntityMaps: e
50715
+ }),
50716
+ n
50717
+ );
50718
+ s.hydrateAncestors(), s.addSelfToProject();
50719
+ }).visit((i) => {
50720
+ const s = n.get(
50721
+ e.get(i.id)
50722
+ );
50723
+ s && s.afterAllChildrenInitialized();
50724
+ }), n.afterAllChildrenInitialized(), n;
50725
+ }
50721
50726
  function q7(r) {
50722
50727
  const e = vT(r);
50723
50728
  return new bT(r).visit((t) => {
@@ -50733,7 +50738,7 @@ function q7(r) {
50733
50738
  n && n.afterAllChildrenInitialized();
50734
50739
  }), e;
50735
50740
  }
50736
- async function Mq(r, e = {}) {
50741
+ async function Nq(r, e = {}) {
50737
50742
  if (r.id && xr[r.id])
50738
50743
  return xr[r.id];
50739
50744
  if (r.id && qi[r.id])
@@ -50747,10 +50752,10 @@ async function Mq(r, e = {}) {
50747
50752
  }
50748
50753
  return null;
50749
50754
  }
50750
- function Nq(r) {
50755
+ function _q(r) {
50751
50756
  return xr[r.id] && delete xr[r.id], null;
50752
50757
  }
50753
- const _q = "test_primitive_entities_export";
50758
+ const Vq = "test_primitive_entities_export";
50754
50759
  export {
50755
50760
  ru as AI_VALUE_CONNECTION_GENERATION_ACTION_EXPLANATION,
50756
50761
  eS as ALL_BUILT_IN_BASE_ENTITIES,
@@ -50940,6 +50945,7 @@ export {
50940
50945
  T7 as checkIsMethod,
50941
50946
  Ko as checkIsNestedScope,
50942
50947
  hs as checkScopeCompatibility,
50948
+ Mq as cloneProject,
50943
50949
  vs as countedLoopActionDescriptor,
50944
50950
  II as countedLoopActionDescriptorDynamicReturnDeclaration,
50945
50951
  gI as countedLoopActionDescriptorDynamicReturnDeclarationParentRef,
@@ -50991,7 +50997,7 @@ export {
50991
50997
  Nf as dateValueAutogenerationSchema,
50992
50998
  Xu as deletePersistedEntityMethod,
50993
50999
  _D as deletePersistedEntityMethodParentRef,
50994
- Nq as deleteRootProject,
51000
+ _q as deleteRootProject,
50995
51001
  Rs as endpointBuiltInBaseEntity,
50996
51002
  VI as endpointBuiltInBaseEntityRef,
50997
51003
  mD as endpointBuiltInBaseEntityRefFour,
@@ -51210,7 +51216,7 @@ export {
51210
51216
  mq as getPeristedEntities,
51211
51217
  EJ as getPlayableEntityReferenceSchema,
51212
51218
  TJ as getPlayableEntityTypeSchema,
51213
- Mq as getProject,
51219
+ Nq as getProject,
51214
51220
  Oc as getPrototypeByType,
51215
51221
  D as getReferenceEntityId,
51216
51222
  Ao as getReferencedEntitiesStateOrErrors,
@@ -51623,7 +51629,7 @@ export {
51623
51629
  J as stringPrototype,
51624
51630
  Bf as stringValueAutogenerationSchema,
51625
51631
  Qc as suggestNewIdForEntity,
51626
- _q as test_primitive_entities_export,
51632
+ Vq as test_primitive_entities_export,
51627
51633
  CJ as toCamelCase,
51628
51634
  Ft as toEntityState,
51629
51635
  T5 as toKebabCase,