src/sap.ui.integration/src/sap/ui/integration/util/CustomElements.js
function callback(mutationsList, observer) {
			mutationsList.forEach(function (mutation) {
				if (mutation.type == 'childList') {
					var addedNodes = mutation.addedNodes,
						removedNodes = mutation.removedNodes,
						node,
						xnode,
						count,
						aTags,
						i;
					for (count = 0; count < addedNodes.length; count++) {
						node = addedNodes[count];
						if (!document.createCustomElement._querySelector) {
							return;
						}
						if (node.tagName && document.createCustomElement.hasOwnProperty(node.tagName.toLowerCase())) {
							if (!node._control) {
								document.createCustomElement[node.tagName.toLowerCase()].connectToNode(node);
							}
							node._control._connectedCallback();
						}
						if (node.tagName) {
							aTags = node.querySelectorAll(document.createCustomElement._querySelector);
							for (i = 0; i < aTags.length; i++) {
								xnode = aTags[i];
								if (xnode.tagName && document.createCustomElement.hasOwnProperty(xnode.tagName.toLowerCase())) {
									if (!xnode._control) {
										document.createCustomElement[xnode.tagName.toLowerCase()].connectToNode(xnode);
									}
									xnode._control._connectedCallback();
								}
							}
						}
					}
					for (count = 0; count < removedNodes.length; count++) {
						node = removedNodes[count];
						if (!document.createCustomElement._querySelector) {
							return;
						}
						if (node._control) {
							node._control._disconnectedCallback();
						}
						if (node.tagName) {
							aTags = node.querySelectorAll(document.createCustomElement._querySelector);
							for (i = 0; i < aTags.length; i++) {
								xnode = aTags[i];
								if (xnode._control) {
									xnode._control._disconnectedCallback();
								}
							}
						}
					}
				} else if (mutation.type === "attributes" && mutation.target && mutation.target._control) {
					mutation.target._control._changeProperty.call(mutation.target._control, mutation.attributeName, mutation.target.getAttribute(mutation.attributeName));
				}
			});
		}
function callback(mutationsList, observer) {
			mutationsList.forEach(function (mutation) {
				if (mutation.type == 'childList') {
					var addedNodes = mutation.addedNodes,
						removedNodes = mutation.removedNodes,
						node,
						xnode,
						count,
						aTags,
						i;
					for (count = 0; count < addedNodes.length; count++) {
						node = addedNodes[count];
						if (!document.createCustomElement._querySelector) {
							return;
						}
						if (node.tagName && document.createCustomElement.hasOwnProperty(node.tagName.toLowerCase())) {
							if (!node._control) {
								document.createCustomElement[node.tagName.toLowerCase()].connectToNode(node);
							}
							node._control._connectedCallback();
						}
						if (node.tagName) {
							aTags = node.querySelectorAll(document.createCustomElement._querySelector);
							for (i = 0; i < aTags.length; i++) {
								xnode = aTags[i];
								if (xnode.tagName && document.createCustomElement.hasOwnProperty(xnode.tagName.toLowerCase())) {
									if (!xnode._control) {
										document.createCustomElement[xnode.tagName.toLowerCase()].connectToNode(xnode);
									}
									xnode._control._connectedCallback();
								}
							}
						}
					}
					for (count = 0; count < removedNodes.length; count++) {
						node = removedNodes[count];
						if (!document.createCustomElement._querySelector) {
							return;
						}
						if (node._control) {
							node._control._disconnectedCallback();
						}
						if (node.tagName) {
							aTags = node.querySelectorAll(document.createCustomElement._querySelector);
							for (i = 0; i < aTags.length; i++) {
								xnode = aTags[i];
								if (xnode._control) {
									xnode._control._disconnectedCallback();
								}
							}
						}
					}
				} else if (mutation.type === "attributes" && mutation.target && mutation.target._control) {
					mutation.target._control._changeProperty.call(mutation.target._control, mutation.attributeName, mutation.target.getAttribute(mutation.attributeName));
				}
			});
		}
function callback ( mutationsList , observer ) { mutationsList . forEach ( function ( mutation ) { if ( mutation . type == 'childList' ) { var addedNodes = mutation . addedNodes , removedNodes = mutation . removedNodes , node , xnode , count , aTags , i ; for ( count = 0 ; count < addedNodes . length ; count ++ ) { node = addedNodes [ count ] ; if ( ! document . createCustomElement . _querySelector ) { return ; } if ( node . tagName && document . createCustomElement . hasOwnProperty ( node . tagName . toLowerCase ( ) ) ) { if ( ! node . _control ) { document . createCustomElement [ node . tagName . toLowerCase ( ) ] . connectToNode ( node ) ; } node . _control . _connectedCallback ( ) ; } if ( node . tagName ) { aTags = node . querySelectorAll ( document . createCustomElement . _querySelector ) ; for ( i = 0 ; i < aTags . length ; i ++ ) { xnode = aTags [ i ] ; if ( xnode . tagName && document . createCustomElement . hasOwnProperty ( xnode . tagName . toLowerCase ( ) ) ) { if ( ! xnode . _control ) { document . createCustomElement [ xnode . tagName . toLowerCase ( ) ] . connectToNode ( xnode ) ; } xnode . _control . _connectedCallback ( ) ; } } } } for ( count = 0 ; count < removedNodes . length ; count ++ ) { node = removedNodes [ count ] ; if ( ! document . createCustomElement . _querySelector ) { return ; } if ( node . _control ) { node . _control . _disconnectedCallback ( ) ; } if ( node . tagName ) { aTags = node . querySelectorAll ( document . createCustomElement . _querySelector ) ; for ( i = 0 ; i < aTags . length ; i ++ ) { xnode = aTags [ i ] ; if ( xnode . _control ) { xnode . _control . _disconnectedCallback ( ) ; } } } } } else if ( mutation . type === "attributes" && mutation . target && mutation . target . _control ) { mutation . target . _control . _changeProperty . call ( mutation . target . _control , mutation . attributeName , mutation . target . getAttribute ( mutation . attributeName ) ) ; } } ) ; }
Callback function to execute when mutations are observed
Callback function to execute when mutations are observed