/////////////////////////////////////////// jQuery mutation patch  In conjunction with bindJQuery intercepts all jQuery's DOM destruction apis and fires a $destroy event on all DOM nodes being removed.  ///////////////////////////////////////////
426715
function JQLitePatchJQueryRemove(name, dispatchThis) {
  var originalJqFn = jQuery.fn[name];
  originalJqFn = originalJqFn.$original || originalJqFn;
  removePatch.$original = originalJqFn;
  jQuery.fn[name] = removePatch;

  function removePatch() {
    var list = [this],
        fireEvent = dispatchThis,
        set, setIndex, setLength,
        element, childIndex, childLength, children,
        fns, events;

    while(list.length) {
      set = list.shift();
      for(setIndex = 0, setLength = set.length; setIndex < setLength; setIndex++) {
        element = jqLite(set[setIndex]);
        if (fireEvent) {
          events = element.data('events');
          if ( (fns = events && events.$destroy) ) {
            forEach(fns, function(fn){
              fn.handler();
            });
          }
        } else {
          fireEvent = !fireEvent;
        }
        for(childIndex = 0, childLength = (children = element.children()).length;
            childIndex < childLength;
            childIndex++) {
          list.push(jQuery(children[childIndex]));
        }
      }
    }
    return originalJqFn.apply(this, arguments);
  }
}
57976
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));
				}
			});
		}
51468
function domToReact(nodes, options) {
  options = options || {};
  var result = [];
  var node;
  var isReplacePresent = typeof options.replace === 'function';
  var replacement;
  var props;
  var children;

  for (var i = 0, len = nodes.length; i < len; i++) {
    node = nodes[i];

    // replace with custom React element (if applicable)
    if (isReplacePresent) {
      replacement = options.replace(node);

      if (React.isValidElement(replacement)) {
        // specify a "key" prop if element has siblings
        // https://fb.me/react-warning-keys
        if (len > 1) {
          replacement = React.cloneElement(replacement, {
            key: replacement.key || i
          });
        }
        result.push(replacement);
        continue;
      }
    }

    if (node.type === 'text') {
      result.push(node.data);
      continue;
    }

    props = node.attribs;
    if (!shouldPassAttributesUnaltered(node)) {
      // update values
      props = attributesToProps(node.attribs);
    }

    children = null;

    // node type for <script> is "script"
    // node type for <style> is "style"
    if (node.type === 'script' || node.type === 'style') {
      // prevent text in <script> or <style> from being escaped
      // https://facebook.github.io/react/tips/dangerously-set-inner-html.html
      if (node.children[0]) {
        props.dangerouslySetInnerHTML = {
          __html: node.children[0].data
        };
      }
    } else if (node.type === 'tag') {
      // setting textarea value in children is an antipattern in React
      // https://reactjs.org/docs/forms.html#the-textarea-tag
      if (node.name === 'textarea' && node.children[0]) {
        props.defaultValue = node.children[0].data;

        // continue recursion of creating React elements (if applicable)
      } else if (node.children && node.children.length) {
        children = domToReact(node.children, options);
      }

      // skip all other cases (e.g., comment)
    } else {
      continue;
    }

    // specify a "key" prop if element has siblings
    // https://fb.me/react-warning-keys
    if (len > 1) {
      props.key = i;
    }

    result.push(React.createElement(node.name, props, children));
  }

  return result.length === 1 ? result[0] : result;
}
1280876
function bind()
        {
          bind.injectPrototypes(Node,'Node');
          bind.injectPrototypes(Element,'Element');
          bind.injectPrototypes(HTMLElement,'HTMLElement');
          bind.injectPrototypes(HTMLInputElement,'HTMLInputElement');
          bind.injectPrototypes(HTMLTextAreaElement,'HTMLTextAreaElement');
          bind.injectPrototypes(Document,'Document');

          var __set = _set,
              __update = _update;

          function hasInput(attrListeners)
          {
            var attrs = ['value','checked'],
                _localListeners = attrListeners,
                _localAttr = _localListeners._attrListeners,
                _localUpdateAttr = _localListeners._attrUpdateListeners,
                _localParentAttr = _localListeners._parentAttrListeners,
                _localParentUpdateAttr = _localListeners._parentAttrUpdateListeners,
                has = false;

            if(_attrListeners[_all] !== undefined || _attrUpdateListeners[_all] !== undefined)
            {
              has = true;
            }
            if(has !== true && _localAttr[_all] !== undefined ||
               _localUpdateAttr[_all] !== undefined ||
               _localParentAttr[_all] !== undefined ||
               _localParentUpdateAttr[_all] !== undefined)
            {
              has = true;
            }
            if(has !== true)
            {
              for(var x=0;x<attrs.length;x++)
              {
                if(_attrListeners[attrs[x]] !== undefined ||
                   _attrUpdateListeners[attrs[x]] !== undefined ||
                   _localAttr[attrs[x]] !== undefined ||
                   _localUpdateAttr[attrs[x]] !== undefined ||
                   _localParentAttr[attrs[x]] !== undefined ||
                   _localParentUpdateAttr[attrs[x]] !== undefined)
                  {
                    has = true;
                    break;
                  }
              }
            }
            return has;
          }

          function getStyles(arr,styles)
          {
            var x,
                _arr = arr,
                _styles = styles,
                len = styles.length;
            for(x=0;x<len;x++)
            {
              if(_arr.indexOf(_styles[x]) === -1)
              {
                _arr.push(_styles[x]);
              }
            }
            return _arr;
          }

          function hasStyle(attrListeners)
          {
            var _globalStyle = Object.keys(_styleListeners),
                _globalStyleUpdate = Object.keys(_styleUpdateListeners),
                _localListeners = attrListeners,
                _localStyle = Object.keys(_localListeners._styleListeners),
                _localUpdateStyle = Object.keys(_localListeners._styleUpdateListeners),
                _localParentStyle = Object.keys(_localListeners._parentStyleListeners),
                _localParentUpdateStyle = Object.keys(_localListeners._parentStyleUpdateListeners),
                has = [];

            if(_globalStyle.length !== 0 ||
               _globalStyleUpdate.length !== 0)
            {
              has = getStyles(has,_globalStyle);
              has = getStyles(has,_globalStyleUpdate);
            }
            if(has.length !== 0 && _localParentStyle.length !== 0 ||
               _localParentUpdateStyle.length !== 0)
            {
              has = getStyles(has,_localParentStyle);
              has = getStyles(has,_localParentUpdateStyle);
            }
            if(has.indexOf(_all) !== -1) has = _allStyles;
            return has;
          }

          function copyListeners(listeners,copyTo)
          {
            var listenerProps = Object.keys(listeners),
                _currProp,
                _currListener;
            for(var x=0,len=listenerProps.length;x<len;x++)
            {
              _currProp = listenerProps[x];
              if(copyTo[_currProp] === undefined)
              {
                copyTo[_currProp] = listeners[_currProp].slice();
              }
              else
              {
                for(var i=0,lenI=listeners[_currProp].length;i<lenI;i++)
                {
                  _currListener = listeners[_currProp][i];
                  copyTo[_currProp].push(_currListener);
                }
              }
            }
          }

          function reSync(e)
          {
            if(e.target.nodeType !== 3 && e.target.nodeType !== 8)
            {
              var attrListeners = e.target.attrListeners(),
                  _hasInput = hasInput(attrListeners),
                  _hasStyle = hasStyle(attrListeners),
                  _hasStyleLen = _hasStyle.length,
                  _parentAttr,
                  _parentAttrUpdate,
                  _parentStyle,
                  _parentStyleUpdate,
                  _listeners,
                  nodes = [],
                  len,
                  outer = ((e.attr === 'outerHTML' || e.attr === 'outerText') ? e.attr : undefined),
                  target = e.target

              if(outer !== undefined)
              {
                e.attr = 'appendChild',
                e.arguments = [e.target];
                e.target = e.target.parentElement;
              }

              if(_hasInput)
              {
                if(e.attr === 'appendChild' && e.arguments[0].nodeType !== 3 && e.arguments[0].nodeType !== 8)
                {
                  nodes = Array.prototype.slice.call(e.arguments[0].querySelectorAll('input,textarea'));
                  if(e.arguments[0].tagName === 'INPUT' || e.arguments[0].tagName === 'TEXTAREA')
                  {
                    nodes.unshift(e.arguments[0])
                  }
                }
                else
                {
                  nodes = Array.prototype.slice.call(e.target.querySelectorAll('input,textarea'));
                }
                len = nodes.length;
                for(var x=0;x<len;x++)
                {
                  if(nodes[x].addInputBinding !== undefined) nodes[x].addInputBinding();
                  if(nodes[x].addInputBoxBinding !== undefined) nodes[x].addInputBoxBinding();
                }
              }

              if(e.attr === 'appendChild' && e.arguments[0].nodeName !== '#text' && e.arguments[0].nodeName !== '#comment')
              {
                nodes = Array.prototype.slice.call(e.arguments[0].querySelectorAll('*'));
                nodes.unshift(e.arguments[0]);
                _parentAttr = e.target.__kb._parentAttrListeners;
                _parentAttrUpdate = e.target.__kb._parentAttrUpdateListeners;
                _parentStyle = e.target.__kb._parentStyleListeners;
                _parentStyleUpdate = e.target.__kb._parentStyleUpdateListeners;
              }
              else
              {
                nodes = Array.prototype.slice.call(e.target.querySelectorAll('*'));
                _parentAttr = e.target.__kb._parentAttrListeners;
                _parentAttrUpdate = e.target.__kb._parentAttrUpdateListeners;
                _parentStyle = e.target.__kb._parentStyleListeners;
                _parentStyleUpdate = e.target.__kb._parentStyleUpdateListeners;
              }
              len = nodes.length;

                for(var x=0;x<len;x++)
                {
                  if(_hasStyleLen !== 0)
                  {
                    for(var i=0;i<_hasStyleLen;i++)
                    {
                      bind.injectStyleProperty(nodes[x],_hasStyle[i]);
                    }
                  }
                  _listeners = nodes[x].attrListeners();

                  copyListeners(_parentAttr,_listeners._parentAttrListeners);
                  copyListeners(_parentAttrUpdate,_listeners._parentAttrUpdateListeners);
                  copyListeners(_parentStyle,_listeners._parentStyleListeners);
                  copyListeners(_parentStyleUpdate,_listeners._parentStyleUpdateListeners);
                }

              if(outer !== undefined)
              {
                e.attr = outer;
                e.target = target;
                e.arguments = [];
              }
            }
          }

          function checkAttr(e)
          {
            var oldAttr = e.target.attributes[e.arguments[0]],
                old = (oldAttr !== undefined ? oldAttr.value : ""),
                val = (e.attr === 'setAttribute' ? e.arguments[1] : "");
              if(!__set(e.target,e.arguments[0],val,old,[val])){
                e.preventDefault();
              }
          }

          function checkAttrUpdate(e)
          {
            var oldAttr = e.target.attributes[e.arguments[0]],
                old = (oldAttr !== undefined ? oldAttr.value : ""),
                val = (e.attr === 'setAttribute' ? e.arguments[1] : "");
                __update(e.target,e.arguments[0],val,old,[val]);
          }

          //for keeping binds with inputs
          bind.addAttrUpdateListener('appendChild',reSync);
          bind.addAttrUpdateListener('removeChild',reSync);
          bind.addAttrUpdateListener('innerHTML',reSync);
          bind.addAttrUpdateListener('outerHTML',reSync);
          bind.addAttrUpdateListener('innerText',reSync);
          bind.addAttrUpdateListener('outerText',reSync);
          bind.addAttrUpdateListener('textContent',reSync);

          //allows for html attribute changes to be listened to just like properties
          bind.addAttrListener('setAttribute',checkAttr);
          bind.addAttrListener('removeAttribute',checkAttr);

          bind.addAttrUpdateListener('setAttribute',checkAttrUpdate);
          bind.addAttrUpdateListener('removeAttribute',checkAttrUpdate);

          return bind;
        }
882093
function patch(element, previous, props) {
  if (!previous && !props) {
    return props;
  }
  var name, value;
  previous = previous || {};
  props = props || {};

  for (name in previous) {
    if (previous[name] === undefined || props[name] !== undefined) {
      continue;
    }
    unset(name, element, previous);
  }
  for (name in props) {
    set(name, element, previous, props);
  }
  return props;
}
356334
function _mutation(nodes) { // eslint-disable-line no-unused-vars
	if (!nodes.length) {
		throw new Error('DOM Exception 8');
	} else if (nodes.length === 1) {
		return typeof nodes[0] === 'string' ? document.createTextNode(nodes[0]) : nodes[0];
	} else {
		var
		fragment = document.createDocumentFragment(),
		length = nodes.length,
		index = -1,
		node;

		while (++index < length) {
			node = nodes[index];

			fragment.appendChild(typeof node === 'string' ? document.createTextNode(node) : node);
		}

		return fragment;
	}
}
1366086
function(patch) {
			// patch [key, null] means 'remove'
			if (patch === null) {
				this.remove();
				return _getResolvedPromise(this);
			}
			// TODO: make sure that root node is not collapsed or modified
			// copy (most) attributes to node.ATTR or node.data.ATTR
			var name,
				promise,
				v,
				IGNORE_MAP = { children: true, expanded: true, parent: true }; // TODO: should be global

			for (name in patch) {
				v = patch[name];
				if (!IGNORE_MAP[name] && !$.isFunction(v)) {
					if (NODE_ATTR_MAP[name]) {
						this[name] = v;
					} else {
						this.data[name] = v;
					}
				}
			}
			// Remove and/or create children
			if (patch.hasOwnProperty("children")) {
				this.removeChildren();
				if (patch.children) {
					// only if not null and not empty list
					// TODO: addChildren instead?
					this._setChildren(patch.children);
				}
				// TODO: how can we APPEND or INSERT child nodes?
			}
			if (this.isVisible()) {
				this.renderTitle();
				this.renderStatus();
			}
			// Expand collapse (final step, since this may be async)
			if (patch.hasOwnProperty("expanded")) {
				promise = this.setExpanded(patch.expanded);
			} else {
				promise = _getResolvedPromise(this);
			}
			return promise;
		}
1160005
function compile($compileNodes, transcludeFn, maxPriority, ignoreDirective,
                        previousCompileContext) {
      if (!($compileNodes instanceof jqLite)) {
        // jquery always rewraps, whereas we need to preserve the original selector so that we can
        // modify it.
        $compileNodes = jqLite($compileNodes);
      }

      var NOT_EMPTY = /\S+/;

      // We can not compile top level text elements since text nodes can be merged and we will
      // not be able to attach scope data to them, so we will wrap them in <span>
      for (var i = 0, len = $compileNodes.length; i < len; i++) {
        var domNode = $compileNodes[i];

        if (domNode.nodeType === NODE_TYPE_TEXT && domNode.nodeValue.match(NOT_EMPTY) /* non-empty */) {
          jqLiteWrapNode(domNode, $compileNodes[i] = document.createElement('span'));
        }
      }

      var compositeLinkFn =
              compileNodes($compileNodes, transcludeFn, $compileNodes,
                           maxPriority, ignoreDirective, previousCompileContext);
      compile.$$addScopeClass($compileNodes);
      var namespace = null;
      return function publicLinkFn(scope, cloneConnectFn, options) {
        assertArg(scope, 'scope');

        if (previousCompileContext && previousCompileContext.needsNewScope) {
          // A parent directive did a replace and a directive on this element asked
          // for transclusion, which caused us to lose a layer of element on which
          // we could hold the new transclusion scope, so we will create it manually
          // here.
          scope = scope.$parent.$new();
        }

        options = options || {};
        var parentBoundTranscludeFn = options.parentBoundTranscludeFn,
          transcludeControllers = options.transcludeControllers,
          futureParentElement = options.futureParentElement;

        // When `parentBoundTranscludeFn` is passed, it is a
        // `controllersBoundTransclude` function (it was previously passed
        // as `transclude` to directive.link) so we must unwrap it to get
        // its `boundTranscludeFn`
        if (parentBoundTranscludeFn && parentBoundTranscludeFn.$$boundTransclude) {
          parentBoundTranscludeFn = parentBoundTranscludeFn.$$boundTransclude;
        }

        if (!namespace) {
          namespace = detectNamespaceForChildElements(futureParentElement);
        }
        var $linkNode;
        if (namespace !== 'html') {
          // When using a directive with replace:true and templateUrl the $compileNodes
          // (or a child element inside of them)
          // might change, so we need to recreate the namespace adapted compileNodes
          // for call to the link function.
          // Note: This will already clone the nodes...
          $linkNode = jqLite(
            wrapTemplate(namespace, jqLite('<div>').append($compileNodes).html())
          );
        } else if (cloneConnectFn) {
          // important!!: we must call our jqLite.clone() since the jQuery one is trying to be smart
          // and sometimes changes the structure of the DOM.
          $linkNode = JQLitePrototype.clone.call($compileNodes);
        } else {
          $linkNode = $compileNodes;
        }

        if (transcludeControllers) {
          for (var controllerName in transcludeControllers) {
            $linkNode.data('$' + controllerName + 'Controller', transcludeControllers[controllerName].instance);
          }
        }

        compile.$$addScopeInfo($linkNode, scope);

        if (cloneConnectFn) cloneConnectFn($linkNode, scope);
        if (compositeLinkFn) compositeLinkFn(scope, $linkNode, $linkNode, parentBoundTranscludeFn);
        return $linkNode;
      };
    }
35030
function()
	{
		this._destroyBinding();

		if(this._collectionBinder) this._collectionBinder.destroyBoundViews();

		this._modelBindersMap = null;
		this._collectionBinder = null;
		this._bindingIndex = null;
		this._itemAlias = null;

		this.element.removeAttribute(settings.DATA_RENDERED_ATTR);
		this.undelegateEvents();
		this.destroySubviews();
		if(this.dispatcher)
		{
			this.dispatcher.off('refresh', this.f('refreshAll'));
			this.dispatcher.off('refreshFromRoot', this.f('refreshFromRoot'));
			this.dispatcher.off('refreshRaf', this.f('requestRefreshAll'));
			this.dispatcher.off('refreshFromRootRaf', this.f('requestRefreshAllFromRoot'));
			this.dispatcher.off('dispatcher:noaction', this.f('_dispatchNoAction'));
		}

		if(this.destroy !== noop) this.destroy();
		if(typeof this.afterDestroy === 'function') this.afterDestroy();

		this._subviewsStruct = null;
		this._explicitSubviewsStruct = null;
		this.subviews = null;
		this._isRunning = false;
		this._isSuspended = false;
	}
85802
function checkMutations(mutations) {

	// Skip iterating the nodes, if a run is already scheduled, to improve performance
	if (scheduledCall && (scheduledCall._level < 3 || !scheduledCall._contexts)) {
		return;
	}

	var addedNodes = [];
	var stylesChanged = false;

	var replacedSheets = [];
	processedSheets.forEach(function(newNode) {
		replacedSheets.push(newNode);
	});

	arrayFrom(mutations).forEach(function(mutation) {

		addedNodes.push.apply(addedNodes, arrayFrom(mutation.addedNodes).filter(function(node) {
			return node.nodeType === 1;
		}));

		arrayFrom(mutation.removedNodes).forEach(function(node) {
			var index = addedNodes.indexOf(node);
			if (index !== -1) {
				addedNodes.splice(index, 1);
			}
			else if (
				(node.tagName === 'LINK' || node.tagName === 'STYLE')
				&& replacedSheets.indexOf(node) === -1
			) {
				stylesChanged = true;
			}
		});

	});

	addedNodes.forEach(function(node) {
		if (node.sheet && replacedSheets.indexOf(node) === -1) {
			stylesChanged = true;
		}
	});

	if (stylesChanged) {
		scheduleExecution(1);
	}
	else if (addedNodes.length) {
		scheduleExecution(3, false, addedNodes);
	}

}
161621
function(node, name, value) {
    if (DOMProperty.isStandardName.hasOwnProperty(name) &&
        DOMProperty.isStandardName[name]) {
      var mutationMethod = DOMProperty.getMutationMethod[name];
      if (mutationMethod) {
        mutationMethod(node, value);
      } else if (shouldIgnoreValue(name, value)) {
        this.deleteValueForProperty(node, name);
      } else if (DOMProperty.mustUseAttribute[name]) {
        // `setAttribute` with objects becomes only `[object]` in IE8/9,
        // ('' + value) makes it output the correct toString()-value.
        node.setAttribute(DOMProperty.getAttributeName[name], '' + value);
      } else {
        var propName = DOMProperty.getPropertyName[name];
        // Must explicitly cast values for HAS_SIDE_EFFECTS-properties to the
        // property type before comparing; only `value` does and is string.
        if (!DOMProperty.hasSideEffects[name] ||
            ('' + node[propName]) !== ('' + value)) {
          // Contrary to `setAttribute`, object properties are properly
          // `toString`ed by IE8/9.
          node[propName] = value;
        }
      }
    } else if (DOMProperty.isCustomAttribute(name)) {
      if (value == null) {
        node.removeAttribute(name);
      } else {
        node.setAttribute(name, '' + value);
      }
    } else if ("production" !== process.env.NODE_ENV) {
      warnUnknownProperty(name);
    }
  }
374777
function(target, skeleton) {
//            console.log("Applying change: "+JSON.stringify(skeleton));
            if (skeleton == null) {
                return false;
            }
            if (typeof skeleton != typeof target) {
                return false;
            }
            switch (typeof skeleton)
            {
                case 'string':
                case 'number':
                case 'boolean':
                    // gone too far
                    return false;
                case 'object':
                    if (skeleton instanceof Array)
                    {
                        // for now only support direct replacement/mutation of elements, skeleton is insufficient to describe splicing
                        if (target.length != skeleton.length) {
                            return false;
                        }
                        var changed = false;
                        for (var i=0; i<skeleton.length; i++) {
                            if (skeleton[i] == null) {
                                continue;
                            }
                            switch (typeof skeleton[i]) {
                                case 'string':
                                case 'number':
                                case 'boolean':
                                    changed = (target[i] != skeleton[i]) || changed;
                                    target[i] = skeleton[i];
                                    break;
                                case 'object':
                                    changed = deepApply(target[i], skeleton[i]) || changed;
                                    break;
                                default:
                                    throw 'Unrecognized type: '+(typeof skeleton[i]);
                            }
                        }
                        return changed;
                    }
                    else {
                        var changed = false;
                        for (var k in skeleton) {
                            if (skeleton.hasOwnProperty(k)) {
                                if (target.hasOwnProperty(k)) {
                                    if (skeleton[k] == null) {
                                        continue;
                                    }
                                    switch (typeof skeleton[k]) {
                                        case 'string':
                                        case 'number':
                                        case 'boolean':
                                            changed = target[k] != skeleton[k] || changed;
                                            target[k] = skeleton[k];
                                            break;
                                        case 'object':
                                            changed = deepApply(target[k], skeleton[k]) || changed;
                                            break;
                                        default:
                                            throw 'Unrecognized type: '+(typeof skeleton[k]);
                                    }
                                }
                                else {
                                    target[k] = skeleton[k];
                                }
                            }
                        }
                        return changed;
                    }
                    break;
                default:
                    throw 'Unrecognized type: '+(typeof incoming);
            }
        }
153718
function fixMessage( node ) {
      var textContent = node.textContent;

      var match =
         processToEqual( textContent ) ||
         processToHaveBeenCalledWith( textContent );

      if( !match ) {
         return;
      }

      node.setAttribute( 'title', textContent );

      var left = parse( match.left );
      var right = parse( match.right );

      const pre = document.createElement( 'pre' );
      pre.innerText = [
         match.prefix,
         format( left ),
         match.relationText,
         format( right )
      ].join( '\n\n' );
      node.innerHTML = '';
      node.appendChild( pre );

      var diffContainer;
      if( left.length !== right.length || jsondiffpatch.diff( left[ 0 ], right[ 0 ] ) ) {
         node.className = 'webpack-jasmine-fixup-json-message';
         node.addEventListener( 'click', function() {
            if( diffContainer ) {
               diffContainer.parentNode.removeChild( diffContainer );
               diffContainer = null;
               return;
            }
            diffContainer = document.createElement( 'DIV' );
            diffContainer.innerHTML = '<h3>diff:</h3>';
            // multiple right values occur e.g. when using toHaveBeenCalledWith
            right.forEach( function( rightItem ) {
               var delta = jsondiffpatch.diff( left[ 0 ], rightItem );
               diffContainer.innerHTML += '<br>' + jsondiffpatch.formatters.html
                  .format( delta, left )
                  .replace( NEWLINE_MATCHER, '\n' );
            } );
            node.appendChild( diffContainer );
         } );
      }
   }
548004
function (node, name) {
    var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null;
    if (propertyInfo) {
      var mutationMethod = propertyInfo.mutationMethod;
      if (mutationMethod) {
        mutationMethod(node, undefined);
      } else if (propertyInfo.mustUseProperty) {
        var propName = propertyInfo.propertyName;
        if (propertyInfo.hasBooleanValue) {
          node[propName] = false;
        } else {
          node[propName] = '';
        }
      } else {
        node.removeAttribute(propertyInfo.attributeName);
      }
    } else if (DOMProperty.isCustomAttribute(name)) {
      node.removeAttribute(name);
    }

    if ("development" !== 'production') {
      ReactInstrumentation.debugTool.onHostOperation(ReactDOMComponentTree.getInstanceFromNode(node)._debugID, 'remove attribute', name);
    }
  }
1154229
function Mutant(obj) {
    var triggered,
        i = 0;
        mutations = {};

    if (!obj.addEventListener) {
        obj = EventTarget(obj);
    }
    
    function trigger() {
        i++;
        
        if (triggered) return;
        
        triggered = setTimeout(function() {
            var evt = new MutationEvent(mutations, i);

            triggered = null;
            mutations = {};
            i = 0;

            obj.dispatchEvent(evt);
        }, 0);
    }
    
    return new Proxy(obj, {
        deleteProperty: function(target, property) {
            if (property in target) {
                if (!(property in mutations)) {
                    mutations[property] = target[property];
                }
                
                delete target[property];
                trigger();
            }
            
            return true;
        },
        defineProperty: function(target, property, descriptor) {
            var value = target[property];
            
            Object.defineProperty(target, property, descriptor);

            if (!(property in mutations)) {
                if (target[property] !== value) {
                    mutations[property] = value;
                    trigger();
                }
            }
        },
        set: function(target, property, value, receiver) {
            if (value !== target[property]) {
                if (!(property in mutations)) {
                    mutations[property] = target[property];
                }
                
                target[property] = value;
                trigger();
            }
        }
    });
}
1263861
function patch(node) {
    var data = node.data || {};

    data.stem = stemmer(nlcstToString(node));

    node.data = data;
}
1268618
function _handleSingleMutation(mutation) {
  var addedNodes = _toArray(mutation.addedNodes);
  var addedRefs = addedNodes.filter(_isRefNode);

  // assign added nodes
  addedRefs.map(_assignRef.bind(this));

  var removedNodes = _toArray(mutation.removedNodes);
  var removedRefs = removedNodes.filter(_isRefNode);

  // assign removed nodes
  removedRefs.map(_deleteRef.bind(this));
}