()
| 289 | * _runMutationObserver |
| 290 | */ |
| 291 | _bindMutationObserver() { |
| 292 | this._observer = new MutationObserver((mutationList) => { |
| 293 | for (let mutation of mutationList) { |
| 294 | // the attributes changes should be handled by attributeChangedCallback() |
| 295 | if (mutation.type === 'childList') { |
| 296 | this._runMutationObserver(mutation.addedNodes); |
| 297 | } |
| 298 | } |
| 299 | }); |
| 300 | // childList observes immediate children only (not grandchildren etc) |
| 301 | this._observer.observe(this, { |
| 302 | childList: true |
| 303 | }); |
| 304 | } |
| 305 | _runMutationObserver(elementsGroup) { |
| 306 | const _addMetaElement = (mapMeta) => { |
| 307 | this.whenReady().then(() => { |
no test coverage detected