angular-three 1.2.2 → 1.2.3

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.
@@ -1697,8 +1697,8 @@ class NgtRendererStore {
1697
1697
  isCompound(name) {
1698
1698
  return this.root.compoundPrefixes.some((prefix) => name.startsWith(prefix));
1699
1699
  }
1700
- isDocument(node) {
1701
- return node === this.root.document;
1700
+ isDOM(node) {
1701
+ return node instanceof Element || node instanceof Document;
1702
1702
  }
1703
1703
  get rootScene() {
1704
1704
  return this.root.store.get('scene');
@@ -2151,8 +2151,8 @@ class NgtRenderer {
2151
2151
  }
2152
2152
  }
2153
2153
  listen(target, eventName, callback) {
2154
- // if target is Document (DOM), then we pass that to delegate Renderer
2155
- if (this.store.isDocument(target)) {
2154
+ // if target is DOM node, then we pass that to delegate Renderer
2155
+ if (this.store.isDOM(target)) {
2156
2156
  return this.delegate.listen(target, eventName, callback);
2157
2157
  }
2158
2158
  if (target.__ngt_renderer__[0 /* NgtRendererClassId.type */] === 'three' ||