{"version":3,"sources":["node_modules\\react-dom\\lib\\instantiateReactComponent.js"],"names":["_prodInvariant","require","_assign","ReactCompositeComponent","ReactEmptyComponent","ReactHostComponent","getNextDebugID","invariant","warning","ReactCompositeComponentWrapper","element","construct","getDeclarationErrorAddendum","owner","name","getName","isInternalComponentType","type","prototype","mountComponent","receiveComponent","instantiateReactComponent","node","shouldHaveDebugID","instance","create","info","process","env","NODE_ENV","undefined","Object","keys","length","_owner","createInternalComponent","getHostNode","getNativeNode","createInstanceForText","unmountComponent","_mountIndex","_mountImage","_debugID","preventExtensions","_instantiateReactComponent","module","exports"],"mappings":";;;;;;;;;;AAUA;;AAEA,GAAIA,gBAAiBC,QAAQ,sBAAR,CAArB;AACIC,QAAUD,QAAQ,eAAR,CADd;;AAGA,GAAIE,yBAA0BF,QAAQ,2BAAR,CAA9B;AACA,GAAIG,qBAAsBH,QAAQ,uBAAR,CAA1B;AACA,GAAII,oBAAqBJ,QAAQ,sBAAR,CAAzB;;AAEA,GAAIK,gBAAiBL,QAAQ,0BAAR,CAArB;AACA,GAAIM,WAAYN,QAAQ,oBAAR,CAAhB;AACA,GAAIO,SAAUP,QAAQ,kBAAR,CAAd;;;AAGA,GAAIQ,gCAAiC,QAAjCA,+BAAiC,CAAUC,OAAV,CAAmB;AACtD,KAAKC,SAAL,CAAeD,OAAf;AACD,CAFD;;AAIA,QAASE,4BAAT,CAAqCC,KAArC,CAA4C;AAC1C,GAAIA,KAAJ,CAAW;AACT,GAAIC,MAAOD,MAAME,OAAN,EAAX;AACA,GAAID,IAAJ,CAAU;AACR,MAAO,gCAAkCA,IAAlC,CAAyC,IAAhD;AACD;AACF;AACD,MAAO,EAAP;AACD;;;;;;;;;AASD,QAASE,wBAAT,CAAiCC,IAAjC,CAAuC;AACrC,MAAO,OAAOA,KAAP,GAAgB,UAAhB,EAA8B,MAAOA,MAAKC,SAAZ,GAA0B,WAAxD,EAAuE,MAAOD,MAAKC,SAAL,CAAeC,cAAtB,GAAyC,UAAhH,E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,GAAyB,YAA7B,CAA2C;AACzC,GAAIE,OAAOY,iBAAX,CAA8B;AAC5BZ,OAAOY,iBAAP,CAAyBnB,QAAzB;AACD;AACF;;AAED,MAAOA,SAAP;AACD;;AAEDtB,QAAQO,+BAA+BS,SAAvC,CAAkDf,uBAAlD,CAA2E;AACzEyC,2BAA4BvB,yBAD6C,CAA3E;;;AAIAwB,OAAOC,OAAP,CAAiBzB,yBAAjB","file":"instantiateReactComponent.js","sourceRoot":"D:/Work/Office/react-native-on-web/cli/tmpl/project","sourcesContent":["/**\n * Copyright 2013-present, Facebook, Inc.\n * All rights reserved.\n *\n * This source code is licensed under the BSD-style license found in the\n * LICENSE file in the root directory of this source tree. An additional grant\n * of patent rights can be found in the PATENTS file in the same directory.\n *\n */\n\n'use strict';\n\nvar _prodInvariant = require('./reactProdInvariant'),\n    _assign = require('object-assign');\n\nvar ReactCompositeComponent = require('./ReactCompositeComponent');\nvar ReactEmptyComponent = require('./ReactEmptyComponent');\nvar ReactHostComponent = require('./ReactHostComponent');\n\nvar getNextDebugID = require('react/lib/getNextDebugID');\nvar invariant = require('fbjs/lib/invariant');\nvar warning = require('fbjs/lib/warning');\n\n// To avoid a cyclic dependency, we create the final class in this module\nvar ReactCompositeComponentWrapper = function (element) {\n  this.construct(element);\n};\n\nfunction getDeclarationErrorAddendum(owner) {\n  if (owner) {\n    var name = owner.getName();\n    if (name) {\n      return ' Check the render method of `' + name + '`.';\n    }\n  }\n  return '';\n}\n\n/**\n * Check if the type reference is a known internal type. I.e. not a user\n * provided composite type.\n *\n * @param {function} type\n * @return {boolean} Returns true if this is a valid internal type.\n */\nfunction isInternalComponentType(type) {\n  return typeof type === 'function' && typeof type.prototype !== 'undefined' && typeof type.prototype.mountComponent === 'function' && typeof type.prototype.receiveComponent === 'function';\n}\n\n/**\n * Given a ReactNode, create an instance that will actually be mounted.\n *\n * @param {ReactNode} node\n * @param {boolean} shouldHaveDebugID\n * @return {object} A new instance of the element's constructor.\n * @protected\n */\nfunction instantiateReactComponent(node, shouldHaveDebugID) {\n  var instance;\n\n  if (node === null || node === false) {\n    instance = ReactEmptyComponent.create(instantiateReactComponent);\n  } else if (typeof node === 'object') {\n    var element = node;\n    var type = element.type;\n    if (typeof type !== 'function' && typeof type !== 'string') {\n      var info = '';\n      if (process.env.NODE_ENV !== 'production') {\n        if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) {\n          info += ' You likely forgot to export your component from the file ' + \"it's defined in.\";\n        }\n      }\n      info += getDeclarationErrorAddendum(element._owner);\n      !false ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s', type == null ? type : typeof type, info) : _prodInvariant('130', type == null ? type : typeof type, info) : void 0;\n    }\n\n    // Special case string values\n    if (typeof element.type === 'string') {\n      instance = ReactHostComponent.createInternalComponent(element);\n    } else if (isInternalComponentType(element.type)) {\n      // This is temporarily available for custom components that are not string\n      // representations. I.e. ART. Once those are updated to use the string\n      // representation, we can drop this code path.\n      instance = new element.type(element);\n\n      // We renamed this. Allow the old name for compat. :(\n      if (!instance.getHostNode) {\n        instance.getHostNode = instance.getNativeNode;\n      }\n    } else {\n      instance = new ReactCompositeComponentWrapper(element);\n    }\n  } else if (typeof node === 'string' || typeof node === 'number') {\n    instance = ReactHostComponent.createInstanceForText(node);\n  } else {\n    !false ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Encountered invalid React node of type %s', typeof node) : _prodInvariant('131', typeof node) : void 0;\n  }\n\n  if (process.env.NODE_ENV !== 'production') {\n    process.env.NODE_ENV !== 'production' ? warning(typeof instance.mountComponent === 'function' && typeof instance.receiveComponent === 'function' && typeof instance.getHostNode === 'function' && typeof instance.unmountComponent === 'function', 'Only React Components can be mounted.') : void 0;\n  }\n\n  // These two fields are used by the DOM and ART diffing algorithms\n  // respectively. Instead of using expandos on components, we should be\n  // storing the state needed by the diffing algorithms elsewhere.\n  instance._mountIndex = 0;\n  instance._mountImage = null;\n\n  if (process.env.NODE_ENV !== 'production') {\n    instance._debugID = shouldHaveDebugID ? getNextDebugID() : 0;\n  }\n\n  // Internal instances should fully constructed at this point, so they should\n  // not get any new fields added to them at this point.\n  if (process.env.NODE_ENV !== 'production') {\n    if (Object.preventExtensions) {\n      Object.preventExtensions(instance);\n    }\n  }\n\n  return instance;\n}\n\n_assign(ReactCompositeComponentWrapper.prototype, ReactCompositeComponent, {\n  _instantiateReactComponent: instantiateReactComponent\n});\n\nmodule.exports = instantiateReactComponent;"]}