angular-three 1.9.3 → 1.9.5

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.
@@ -546,8 +546,10 @@ class NgtRxStore extends RxState {
546
546
  Object.defineProperty(this, 'get', {
547
547
  get: () => {
548
548
  return (...args) => {
549
- const state = originalGet(...args);
550
- return state || {};
549
+ if (args.length === 0) {
550
+ return originalGet() ?? {};
551
+ }
552
+ return originalGet(...args);
551
553
  };
552
554
  },
553
555
  });
@@ -2000,20 +2002,15 @@ class NgtRendererStore {
2000
2002
  class NgtRendererFactory {
2001
2003
  constructor() {
2002
2004
  this.delegateRendererFactory = inject(RendererFactory2, { skipSelf: true });
2003
- this.cdr = inject(ChangeDetectorRef);
2004
- this.store = inject(NgtStore);
2005
2005
  this.catalogue = inject(NGT_CATALOGUE);
2006
- this.compoundPrefixes = inject(NGT_COMPOUND_PREFIXES);
2007
- this.document = inject(DOCUMENT);
2008
2006
  this.rendererMap = new Map();
2009
2007
  this.routedSet = new Set();
2010
- this.portals = [];
2011
2008
  this.rendererStore = new NgtRendererStore({
2012
- store: this.store,
2013
- cdr: this.cdr,
2014
- portals: this.portals,
2015
- compoundPrefixes: this.compoundPrefixes,
2016
- document: this.document,
2009
+ store: inject(NgtStore),
2010
+ cdr: inject(ChangeDetectorRef),
2011
+ portals: [],
2012
+ compoundPrefixes: inject(NGT_COMPOUND_PREFIXES),
2013
+ document: inject(DOCUMENT),
2017
2014
  });
2018
2015
  }
2019
2016
  createRenderer(hostElement, type) {
@@ -2568,9 +2565,7 @@ class NgtCanvas extends NgtRxStore {
2568
2565
  compoundPrefixes: this.compoundPrefixes,
2569
2566
  }),
2570
2567
  ], this.envInjector);
2571
- this.glRef = this.glAnchor.createComponent(this.sceneGraph, {
2572
- environmentInjector: this.glEnvInjector,
2573
- });
2568
+ this.glRef = this.glAnchor.createComponent(this.sceneGraph, { environmentInjector: this.glEnvInjector });
2574
2569
  this.glRef.changeDetectorRef.detach();
2575
2570
  this.setSceneGraphInputs();
2576
2571
  // here, we override the detectChanges to also call detectChanges on the ComponentRef