Register a component into the instance map and starts scroll value
monitoring
@param {ReactComponent} nextComponent component instance to render
@param {DOMElement} container container to render into
@return {string} reactRoot ID prefix
779786
function(nextComponent, container) {
    ("production" !== process.env.NODE_ENV ? invariant(
      container && (
        (container.nodeType === ELEMENT_NODE_TYPE || container.nodeType === DOC_NODE_TYPE)
      ),
      '_registerComponent(...): Target container is not a DOM element.'
    ) : invariant(container && (
      (container.nodeType === ELEMENT_NODE_TYPE || container.nodeType === DOC_NODE_TYPE)
    )));

    ReactBrowserEventEmitter.ensureScrollValueMonitoring();

    var reactRootID = ReactMount.registerContainer(container);
    instancesByReactRootID[reactRootID] = nextComponent;
    return reactRootID;
  }
296341
function() {
            var n_components = 0;
            var componentRendered = _.bind(function() {
                n_components = n_components + 1;
                if (n_components >= this.countComponents) {
                    this.ready();
                }
            }, this);

            if (_.size(this.components) == 0) { this.ready(); return this; }

            var addComponent = _.bind(Q.fbind(function(component) {
                this.$("component[data-component='"+component.cid+"']").replaceWith(component.$el);
                component.defer(_.once(componentRendered));

                return Q.try(function() {
                    component.update();
                }).fail(function(err) {
                    logging.exception(err, "Error rendering component:");
                })
            }), this);

            _.each(this.components, function(value, cid) {
                if (_.isArray(value)) {
                    _.each(value, addComponent);
                } else {
                    addComponent(value);
                }
            });

            this.trigger("components:render");
            return this;
        }
1019938
function createComponent(Ctor, props, context) {
    var list = components[Ctor.name],
      inst;

    if (Ctor.prototype && Ctor.prototype.render) {
      inst = new Ctor(props, context);
      Component.call(inst, props, context);
    } else {
      inst = new Component(props, context);
      inst.constructor = Ctor;
      inst.render = doRender;
    }

    if (list) {
      for (var i = list.length; i--; ) {
        if (list[i].constructor === Ctor) {
          inst.nextBase = list[i].nextBase;
          list.splice(i, 1);
          break;
        }
      }
    }
    return inst;
  }
746646
function initRender (vm) {
  vm._vnode = null; // the root of the child tree
  vm._staticTrees = null;
  var parentVnode = vm.$vnode = vm.$options._parentVnode; // the placeholder node in parent tree
  var renderContext = parentVnode && parentVnode.context;
  /**
   * react-vue change
   */
  // vm.$slots = resolveSlots(vm.$options._renderChildren, renderContext)
  vm.$scopedSlots = emptyObject;
  // bind the createElement fn to this instance
  // so that we get proper render context inside it.
  // args order: tag, data, children, normalizationType, alwaysNormalize
  // internal version is used by render functions compiled from templates
  vm._c = function (a, b, c, d) { return createElement(vm, a, b, c, d, false); };
  // normalization is always applied for the public version, used in
  // user-written render functions.
  vm.$createElement = function (a, b, c, d) { return createElement(vm, a, b, c, d, true); };
}
932276
public ComponentAdapter registerComponentInstance(Object componentKey, Object componentInstance) throws PicoRegistrationException {
		if (componentInstance instanceof MutablePicoContainer) {
			MutablePicoContainer pc = (MutablePicoContainer) componentInstance;
			Object contrivedKey = new Object();
			String contrivedComp = "";
			pc.registerComponentInstance(contrivedKey, contrivedComp);
			try {
				if (this.getComponentInstance(contrivedKey) != null) {
					throw new PicoRegistrationException("Cannot register a container to itself. The container is already implicitly registered.");
				}
			} finally {
				pc.unregisterComponent(contrivedKey);
			}

		}
		ComponentAdapter componentAdapter = new InstanceComponentAdapter(componentKey, componentInstance);
		registerComponent(componentAdapter);
		return componentAdapter;
	}
1254363
function redataComponent(_ref, WrappedComponent) {
    var load = _ref.load,
        shouldReload = _ref.shouldReload,
        mapper = _ref.mapper;

    var RedataComponent = function (_PureComponent) {
        _inherits(RedataComponent, _PureComponent);

        function RedataComponent(props) {
            _classCallCheck(this, RedataComponent);

            var _this = _possibleConstructorReturn(this, (RedataComponent.__proto__ || Object.getPrototypeOf(RedataComponent)).call(this, props));

            _this._handleLoadResult = _this._handleLoadResult.bind(_this);

            // If it's in the browser, check if there is data coming from server side rendering.
            // If server data not available, or if this is not in browser, do first load.
            typeof window !== 'undefined' && _this._loadFromServerRender() || _this._load();

            _this.state = _extends({}, data);

            // console.log('data', JSON.parse(JSON.stringify(data)));
            return _this;
        }

        _createClass(RedataComponent, [{
            key: 'componentWillUpdate',
            value: function componentWillUpdate(nextProps, nextState) {
                var props = this.props,
                    state = this.state;

                // If data no longer valid, start loading.

                shouldReload({ props: props, nextProps: nextProps, state: state, nextState: nextState, data: data }) && this._load();
            }
        }, {
            key: 'render',
            value: function render() {
                // Render wrapped component passing the received props and the spreaded data.
                return _react2.default.createElement(WrappedComponent, _extends({}, this.props, this.state));
            }
        }, {
            key: '_load',
            value: function _load() {
                var props = this.props,
                    state = this.state;


                load({ props: props, state: state }).then(this._handleLoadResult);
            }
        }, {
            key: '_loadFromServerRender',
            value: function _loadFromServerRender() {
                var componentUniqueId = this._componentUniqueId();

                // If data was already available from server.
                if (window.__redata && window.__redata.store && window.__redata.store[componentUniqueId]) {
                    // Store server data in our data.
                    var serverData = window.__redata.store[componentUniqueId];

                    data.loading = serverData.loading;
                    data.error = serverData.error;
                    data.result = serverData.result;

                    this._handleLoadResult(data);

                    return true; // Was able to load from global store.
                }

                return false; // Was not able to load from global store.
            }
        }, {
            key: '_componentUniqueId',
            value: function _componentUniqueId() {
                // TODO: investigate how to consistently generate this
                return 'foo';
            }
        }, {
            key: '_handleLoadResult',
            value: function _handleLoadResult(data) {
                console.log('new result', data);
                // Map the load result using the mapper and store it in the state, which will trigger a render.
                // this.setState({ ...(mapper(data)) });
                this.setState(_extends({}, data));
            }
        }]);

        return RedataComponent;
    }(_react.PureComponent);

    RedataComponent.displayName = 'Redata(' + getDisplayName(WrappedComponent) + ')';

    return RedataComponent;
}
1052796
function initializeWhenRendered(element) {

  // If the component has been rendered, our height should be nonzero.
  if (element.clientHeight === 0) {
    // Not rendered yet: wait a bit before trying again.
    setTimeout(() => initializeWhenRendered(element), 10);
    return;
  }

  // If we reach this point, the component's elements should by styled.

  // For auto-sizing to work, we need the text copy to have the same border,
  // padding, and other relevant characteristics as the original text area.
  // Since those aspects are affected by CSS, we have to wait until the
  // element is in the document before we can update the text copy.
  const textBoxStyle = getComputedStyle(element.inner);
  const copyContainerStyle = element.$.copyContainer.style;
  copyContainerStyle.borderBottomStyle  = textBoxStyle.borderBottomStyle;
  copyContainerStyle.borderBottomWidth  = textBoxStyle.borderBottomWidth;
  copyContainerStyle.borderLeftStyle    = textBoxStyle.borderLeftStyle;
  copyContainerStyle.borderLeftWidth    = textBoxStyle.borderLeftWidth;
  copyContainerStyle.borderRightStyle   = textBoxStyle.borderRightStyle;
  copyContainerStyle.borderRightWidth   = textBoxStyle.borderRightWidth;
  copyContainerStyle.borderTopStyle     = textBoxStyle.borderTopStyle;
  copyContainerStyle.borderTopWidth     = textBoxStyle.borderTopWidth;
  copyContainerStyle.paddingBottom      = textBoxStyle.paddingBottom;
  copyContainerStyle.paddingLeft        = textBoxStyle.paddingLeft;
  copyContainerStyle.paddingRight       = textBoxStyle.paddingRight;
  copyContainerStyle.paddingTop         = textBoxStyle.paddingTop;

  // Use the extraLine member to gauge the expected height of a single line of
  // text. We can't use lineHeight, because that can be reported as "normal",
  // and we want to know the actual pixel height.
  element.$.extraLine.style.display = 'inherit';
  element[lineHeightSymbol] = element.$.extraLine.clientHeight;

  // Now that we know the line height, we can hide the extra line.
  element.$.extraLine.style.display = 'none';

  // Use the line height in conjunction with minimumRows to establish the
  // overall minimum height of the component.
  setMinimumHeight(element);
}
419953
function (nextProps, nextState) {
            return nextProps.forceRender ||
                this.props.entry !== nextProps.entry ||
                this.props.extensions !== nextProps.extensions;
        }
433908
function ReactComponent(props, context, updater) {
  this.props = props;
  this.context = context;
  this.refs = emptyObject;
  // We initialize the default updater but the real one gets injected by the
  // renderer.
  this.updater = updater || ReactNoopUpdateQueue_1;
}
1248567
private void callDoLayout(Container container)
    {
        container.doLayout();
        int n = container.getComponentCount();
        for (int i=0; i<n; i++)
        {
            Component component = container.getComponent(i);
            if (component instanceof Container)
            {
                Container subContainer = (Container)component;
                callDoLayout(subContainer);
            }
        }
    }
769937
function AnotherBasicComponent(props: { name: string }): React.Node {
    return <div>Bonjour {props.name}!</div>;
}
1276804
function createInternalComponent(element) {
  !genericComponentClass ?  false ? invariant(false, 'There is no registered component for the tag %s', element.type) : _prodInvariant('111', element.type) : void 0;
  return new genericComponentClass(element);
}
807231
function registerComponentHook (
  componentId,
  type, // hook type, could be "lifecycle" or "instance"
  hook, // hook name
  fn
) {
  if (!document || !document.taskCenter) {
    warn("Can't find available \"document\" or \"taskCenter\".");
    return
  }
  if (typeof document.taskCenter.registerHook === 'function') {
    return document.taskCenter.registerHook(componentId, type, hook, fn)
  }
  warn(("Failed to register component hook \"" + type + "@" + hook + "#" + componentId + "\"."));
}
323171
function registerComponent(component) {
    const componentName = dashify(component.name);
    const componentLocalConfig = (component.local instanceof Array) ? component.local : [];
    while (componentLocalConfig.length < component.path.length) {
        componentLocalConfig.push([]);
    }
    const componentPath = component.path.slice(0).map(p => dashify(p));
    const componentRealPath = componentPath.map((p, i) => {
        return componentLocalConfig[i].dirsort ?
            `${(new String(componentLocalConfig[i].dirsort)).padStart(2, '0')}-${p}` : p;
    });
    const componentParent = path.join(app.components.get('path'), ...componentRealPath);
    const componentDirectory = path.join(componentParent, componentName);

    // Create the component directory
    if (!createCollection(app.components.get('path'), [...componentRealPath, componentName], componentLocalConfig)) {
        throw new Error(`Could not create component directory ${componentDirectory}`);
    }

    // Write out the template file
    const componentVariantName = componentName + (component.variant ? `--${dashify(component.variant)}` : '');
    const componentTemplate = path.join(componentDirectory, `${componentVariantName}.${component.extension}`);
    writeFile(componentTemplate, component.template);

    // Write out the preview template
    if (component.preview) {
        writeFile(path.join(componentParent, `_${componentName}-preview.t3s`), component.preview);
    }

    // Configure the component
    configureComponent(path.join(componentDirectory, `${componentName}.config.json`), component, componentPath);
}
968825
function ThemeProvider(props) {
  const { children, theme: localTheme } = props;
  const outerTheme = useTheme();

  warning(
    outerTheme !== null || typeof localTheme !== 'function',
    [
      'Material-UI: you are providing a theme function property ' +
        'to the ThemeProvider component:',
      '<ThemeProvider theme={outerTheme => outerTheme} />',
      '',
      'However, no outer theme is present.',
      'Make sure a theme is already injected higher in the React tree ' +
        'or provide a theme object.',
    ].join('\n'),
  );

  const theme = React.useMemo(() => {
    const output = outerTheme === null ? localTheme : mergeOuterLocalTheme(outerTheme, localTheme);

    if (outerTheme !== null && output) {
      output[nested] = true;
    }

    return output;
  }, [localTheme, outerTheme]);

  return <ThemeContext.Provider value={theme}>{children}</ThemeContext.Provider>;
}
888646
function componentMount(tag$$1, dom, expressions, opts) {
      var __ = tag$$1.__;
      var root = __.root;
      root._tag = tag$$1; // keep a reference to the tag just created

      // Read all the attrs on this instance. This give us the info we need for updateOpts
      parseAttributes.apply(__.parent, [root, root.attributes, function (attr, expr) {
        if (!__.isAnonymous && RefExpr.isPrototypeOf(expr)) { expr.tag = tag$$1; }
        attr.expr = expr;
        __.instAttrs.push(attr);
      }]);

      // update the root adding custom attributes coming from the compiler
      walkAttributes(__.impl.attrs, function (k, v) { __.implAttrs.push({name: k, value: v}); });
      parseAttributes.apply(tag$$1, [root, __.implAttrs, function (attr, expr) {
        if (expr) { expressions.push(expr); }
        else { setAttribute(root, attr.name, attr.value); }
      }]);

      // initialiation
      updateOpts.apply(tag$$1, [__.isLoop, __.parent, __.isAnonymous, opts, __.instAttrs]);

      // add global mixins
      var globalMixin = mixin(GLOBAL_MIXIN);

      if (globalMixin && !__.skipAnonymous) {
        for (var i in globalMixin) {
          if (globalMixin.hasOwnProperty(i)) {
            tag$$1.mixin(globalMixin[i]);
          }
        }
      }

      if (__.impl.fn) { __.impl.fn.call(tag$$1, opts); }

      if (!__.skipAnonymous) { tag$$1.trigger('before-mount'); }

      // parse layout after init. fn may calculate args for nested custom tags
      each(parseExpressions.apply(tag$$1, [dom, __.isAnonymous]), function (e) { return expressions.push(e); });

      tag$$1.update(__.item);

      if (!__.isAnonymous && !__.isInline) {
        while (dom.firstChild) { root.appendChild(dom.firstChild); }
      }

      define(tag$$1, 'root', root);

      // if we need to wait that the parent "mount" or "updated" event gets triggered
      if (!__.skipAnonymous && tag$$1.parent) {
        var p = getImmediateCustomParent(tag$$1.parent);
        p.one(!p.isMounted ? 'mount' : 'updated', function () {
          setMountState.call(tag$$1, true);
        });
      } else {
        // otherwise it's not a child tag we can trigger its mount event
        setMountState.call(tag$$1, true);
      }

      tag$$1.__.wasCreated = true;

      return tag$$1
    }
408768
function instantiateReactComponent(node, shouldHaveDebugID) {
  var instance;

  if (node === null || node === false) {
    instance = ReactEmptyComponent.create(instantiateReactComponent);
  } else if (typeof node === 'object') {
    var element = node;
    var type = element.type;
    if (typeof type !== 'function' && typeof type !== 'string') {
      var info = '';
      if (process.env.NODE_ENV !== 'production') {
        if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) {
          info += ' You likely forgot to export your component from the file ' + "it's defined in.";
        }
      }
      info += getDeclarationErrorAddendum(element._owner);
       true ? 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;
    }

    // Special case string values
    if (typeof element.type === 'string') {
      instance = ReactHostComponent.createInternalComponent(element);
    } else if (isInternalComponentType(element.type)) {
      // This is temporarily available for custom components that are not string
      // representations. I.e. ART. Once those are updated to use the string
      // representation, we can drop this code path.
      instance = new element.type(element);

      // We renamed this. Allow the old name for compat. :(
      if (!instance.getHostNode) {
        instance.getHostNode = instance.getNativeNode;
      }
    } else {
      instance = new ReactCompositeComponentWrapper(element);
    }
  } else if (typeof node === 'string' || typeof node === 'number') {
    instance = ReactHostComponent.createInstanceForText(node);
  } else {
     true ? process.env.NODE_ENV !== 'production' ? invariant(false, 'Encountered invalid React node of type %s', typeof node) : _prodInvariant('131', typeof node) : void 0;
  }

  if (process.env.NODE_ENV !== 'production') {
    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;
  }

  // These two fields are used by the DOM and ART diffing algorithms
  // respectively. Instead of using expandos on components, we should be
  // storing the state needed by the diffing algorithms elsewhere.
  instance._mountIndex = 0;
  instance._mountImage = null;

  if (process.env.NODE_ENV !== 'production') {
    instance._debugID = shouldHaveDebugID ? getNextDebugID() : 0;
  }

  // Internal instances should fully constructed at this point, so they should
  // not get any new fields added to them at this point.
  if (process.env.NODE_ENV !== 'production') {
    if (Object.preventExtensions) {
      Object.preventExtensions(instance);
    }
  }

  return instance;
}