react 15.0.2 → 15.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/react-with-addons.js +1545 -918
- package/dist/react-with-addons.min.js +6 -6
- package/dist/react.js +1515 -1339
- package/dist/react.min.js +6 -6
- package/lib/CSSPropertyOperations.js +5 -5
- package/lib/DOMChildrenOperations.js +41 -6
- package/lib/DOMLazyTree.js +15 -3
- package/lib/DOMPropertyOperations.js +22 -13
- package/lib/LinkedStateMixin.js +1 -0
- package/lib/ReactCSSTransitionGroup.js +5 -0
- package/lib/ReactChildren.js +9 -1
- package/lib/ReactClass.js +1 -0
- package/lib/ReactComponentBrowserEnvironment.js +0 -5
- package/lib/ReactComponentTreeDevtool.js +145 -0
- package/lib/ReactComponentWithPureRenderMixin.js +2 -0
- package/lib/ReactCompositeComponent.js +147 -18
- package/lib/ReactDOM.js +1 -4
- package/lib/ReactDOMComponent.js +51 -11
- package/lib/ReactDOMIDOperations.js +0 -5
- package/lib/ReactDOMInput.js +5 -3
- package/lib/ReactDOMTextComponent.js +7 -6
- package/lib/ReactDebugTool.js +188 -10
- package/lib/ReactDefaultInjection.js +0 -9
- package/lib/ReactElement.js +26 -0
- package/lib/ReactFragment.js +5 -2
- package/lib/ReactInjection.js +0 -2
- package/lib/ReactLink.js +3 -0
- package/lib/ReactMount.js +22 -7
- package/lib/ReactMultiChild.js +21 -0
- package/lib/ReactNativeAttributePayload.js +7 -36
- package/lib/{IOSNativeBridgeEventPlugin.js → ReactNativeBridgeEventPlugin.js} +8 -5
- package/lib/ReactNativeDOMIDOperations.js +3 -6
- package/lib/ReactNativeDefaultInjection.js +15 -12
- package/lib/ReactNativeEventEmitter.js +6 -3
- package/lib/{IOSDefaultEventPluginOrder.js → ReactNativeEventPluginOrder.js} +3 -3
- package/lib/ReactNativeMount.js +24 -7
- package/lib/ReactNativeOperationHistoryDevtool.js +37 -0
- package/lib/ReactNativeTextComponent.js +8 -0
- package/lib/ReactPerf.js +397 -75
- package/lib/ReactReconciler.js +46 -5
- package/lib/ReactServerRendering.js +20 -1
- package/lib/ReactServerRenderingTransaction.js +5 -1
- package/lib/ReactTestUtils.js +8 -0
- package/lib/ReactTransitionGroup.js +5 -0
- package/lib/ReactUpdates.js +21 -3
- package/lib/ReactVersion.js +1 -1
- package/lib/ReactWithAddons.js +1 -1
- package/lib/findDOMNode.js +2 -0
- package/lib/instantiateReactComponent.js +34 -1
- package/lib/onlyChild.js +7 -4
- package/lib/shallowCompare.js +1 -0
- package/lib/update.js +4 -0
- package/package.json +2 -2
- package/lib/ReactDebugInstanceMap.js +0 -102
- package/lib/ReactDefaultPerf.js +0 -316
- package/lib/ReactDefaultPerfAnalysis.js +0 -210
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* React (with addons) v15.0
|
|
2
|
+
* React (with addons) v15.1.0
|
|
3
3
|
*/
|
|
4
4
|
(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.React = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(_dereq_,module,exports){
|
|
5
5
|
/**
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
|
|
16
16
|
'use strict';
|
|
17
17
|
|
|
18
|
-
var ReactDOMComponentTree = _dereq_(
|
|
18
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
19
19
|
|
|
20
20
|
var focusNode = _dereq_(167);
|
|
21
21
|
|
|
@@ -26,7 +26,7 @@ var AutoFocusUtils = {
|
|
|
26
26
|
};
|
|
27
27
|
|
|
28
28
|
module.exports = AutoFocusUtils;
|
|
29
|
-
},{"167":167,"
|
|
29
|
+
},{"167":167,"45":45}],2:[function(_dereq_,module,exports){
|
|
30
30
|
/**
|
|
31
31
|
* Copyright 2013-present Facebook, Inc.
|
|
32
32
|
* All rights reserved.
|
|
@@ -580,7 +580,7 @@ module.exports = CSSProperty;
|
|
|
580
580
|
|
|
581
581
|
var CSSProperty = _dereq_(3);
|
|
582
582
|
var ExecutionEnvironment = _dereq_(159);
|
|
583
|
-
var
|
|
583
|
+
var ReactInstrumentation = _dereq_(76);
|
|
584
584
|
|
|
585
585
|
var camelizeStyleName = _dereq_(161);
|
|
586
586
|
var dangerousStyleValue = _dereq_(130);
|
|
@@ -734,6 +734,10 @@ var CSSPropertyOperations = {
|
|
|
734
734
|
* @param {ReactDOMComponent} component
|
|
735
735
|
*/
|
|
736
736
|
setValueForStyles: function (node, styles, component) {
|
|
737
|
+
if ("development" !== 'production') {
|
|
738
|
+
ReactInstrumentation.debugTool.onNativeOperation(component._debugID, 'update styles', styles);
|
|
739
|
+
}
|
|
740
|
+
|
|
737
741
|
var style = node.style;
|
|
738
742
|
for (var styleName in styles) {
|
|
739
743
|
if (!styles.hasOwnProperty(styleName)) {
|
|
@@ -765,12 +769,8 @@ var CSSPropertyOperations = {
|
|
|
765
769
|
|
|
766
770
|
};
|
|
767
771
|
|
|
768
|
-
ReactPerf.measureMethods(CSSPropertyOperations, 'CSSPropertyOperations', {
|
|
769
|
-
setValueForStyles: 'setValueForStyles'
|
|
770
|
-
});
|
|
771
|
-
|
|
772
772
|
module.exports = CSSPropertyOperations;
|
|
773
|
-
},{"130":130,"159":159,"161":161,"172":172,"179":179,"183":183,"3":3,"
|
|
773
|
+
},{"130":130,"159":159,"161":161,"172":172,"179":179,"183":183,"3":3,"76":76}],5:[function(_dereq_,module,exports){
|
|
774
774
|
/**
|
|
775
775
|
* Copyright 2013-present, Facebook, Inc.
|
|
776
776
|
* All rights reserved.
|
|
@@ -894,7 +894,7 @@ var EventConstants = _dereq_(16);
|
|
|
894
894
|
var EventPluginHub = _dereq_(17);
|
|
895
895
|
var EventPropagators = _dereq_(20);
|
|
896
896
|
var ExecutionEnvironment = _dereq_(159);
|
|
897
|
-
var ReactDOMComponentTree = _dereq_(
|
|
897
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
898
898
|
var ReactUpdates = _dereq_(104);
|
|
899
899
|
var SyntheticEvent = _dereq_(115);
|
|
900
900
|
|
|
@@ -1202,7 +1202,7 @@ var ChangeEventPlugin = {
|
|
|
1202
1202
|
};
|
|
1203
1203
|
|
|
1204
1204
|
module.exports = ChangeEventPlugin;
|
|
1205
|
-
},{"104":104,"115":115,"138":138,"145":145,"146":146,"159":159,"16":16,"17":17,"177":177,"20":20,"
|
|
1205
|
+
},{"104":104,"115":115,"138":138,"145":145,"146":146,"159":159,"16":16,"17":17,"177":177,"20":20,"45":45}],7:[function(_dereq_,module,exports){
|
|
1206
1206
|
/**
|
|
1207
1207
|
* Copyright 2013-present, Facebook, Inc.
|
|
1208
1208
|
* All rights reserved.
|
|
@@ -1218,8 +1218,9 @@ module.exports = ChangeEventPlugin;
|
|
|
1218
1218
|
|
|
1219
1219
|
var DOMLazyTree = _dereq_(8);
|
|
1220
1220
|
var Danger = _dereq_(12);
|
|
1221
|
-
var ReactMultiChildUpdateTypes = _dereq_(
|
|
1222
|
-
var
|
|
1221
|
+
var ReactMultiChildUpdateTypes = _dereq_(82);
|
|
1222
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
1223
|
+
var ReactInstrumentation = _dereq_(76);
|
|
1223
1224
|
|
|
1224
1225
|
var createMicrosoftUnsafeLocalFunction = _dereq_(129);
|
|
1225
1226
|
var setInnerHTML = _dereq_(150);
|
|
@@ -1314,6 +1315,25 @@ function replaceDelimitedText(openingComment, closingComment, stringText) {
|
|
|
1314
1315
|
removeDelimitedText(parentNode, openingComment, closingComment);
|
|
1315
1316
|
}
|
|
1316
1317
|
}
|
|
1318
|
+
|
|
1319
|
+
if ("development" !== 'production') {
|
|
1320
|
+
ReactInstrumentation.debugTool.onNativeOperation(ReactDOMComponentTree.getInstanceFromNode(openingComment)._debugID, 'replace text', stringText);
|
|
1321
|
+
}
|
|
1322
|
+
}
|
|
1323
|
+
|
|
1324
|
+
var dangerouslyReplaceNodeWithMarkup = Danger.dangerouslyReplaceNodeWithMarkup;
|
|
1325
|
+
if ("development" !== 'production') {
|
|
1326
|
+
dangerouslyReplaceNodeWithMarkup = function (oldChild, markup, prevInstance) {
|
|
1327
|
+
Danger.dangerouslyReplaceNodeWithMarkup(oldChild, markup);
|
|
1328
|
+
if (prevInstance._debugID !== 0) {
|
|
1329
|
+
ReactInstrumentation.debugTool.onNativeOperation(prevInstance._debugID, 'replace with', markup.toString());
|
|
1330
|
+
} else {
|
|
1331
|
+
var nextInstance = ReactDOMComponentTree.getInstanceFromNode(markup.node);
|
|
1332
|
+
if (nextInstance._debugID !== 0) {
|
|
1333
|
+
ReactInstrumentation.debugTool.onNativeOperation(nextInstance._debugID, 'mount', markup.toString());
|
|
1334
|
+
}
|
|
1335
|
+
}
|
|
1336
|
+
};
|
|
1317
1337
|
}
|
|
1318
1338
|
|
|
1319
1339
|
/**
|
|
@@ -1321,7 +1341,7 @@ function replaceDelimitedText(openingComment, closingComment, stringText) {
|
|
|
1321
1341
|
*/
|
|
1322
1342
|
var DOMChildrenOperations = {
|
|
1323
1343
|
|
|
1324
|
-
dangerouslyReplaceNodeWithMarkup:
|
|
1344
|
+
dangerouslyReplaceNodeWithMarkup: dangerouslyReplaceNodeWithMarkup,
|
|
1325
1345
|
|
|
1326
1346
|
replaceDelimitedText: replaceDelimitedText,
|
|
1327
1347
|
|
|
@@ -1333,23 +1353,42 @@ var DOMChildrenOperations = {
|
|
|
1333
1353
|
* @internal
|
|
1334
1354
|
*/
|
|
1335
1355
|
processUpdates: function (parentNode, updates) {
|
|
1356
|
+
if ("development" !== 'production') {
|
|
1357
|
+
var parentNodeDebugID = ReactDOMComponentTree.getInstanceFromNode(parentNode)._debugID;
|
|
1358
|
+
}
|
|
1359
|
+
|
|
1336
1360
|
for (var k = 0; k < updates.length; k++) {
|
|
1337
1361
|
var update = updates[k];
|
|
1338
1362
|
switch (update.type) {
|
|
1339
1363
|
case ReactMultiChildUpdateTypes.INSERT_MARKUP:
|
|
1340
1364
|
insertLazyTreeChildAt(parentNode, update.content, getNodeAfter(parentNode, update.afterNode));
|
|
1365
|
+
if ("development" !== 'production') {
|
|
1366
|
+
ReactInstrumentation.debugTool.onNativeOperation(parentNodeDebugID, 'insert child', { toIndex: update.toIndex, content: update.content.toString() });
|
|
1367
|
+
}
|
|
1341
1368
|
break;
|
|
1342
1369
|
case ReactMultiChildUpdateTypes.MOVE_EXISTING:
|
|
1343
1370
|
moveChild(parentNode, update.fromNode, getNodeAfter(parentNode, update.afterNode));
|
|
1371
|
+
if ("development" !== 'production') {
|
|
1372
|
+
ReactInstrumentation.debugTool.onNativeOperation(parentNodeDebugID, 'move child', { fromIndex: update.fromIndex, toIndex: update.toIndex });
|
|
1373
|
+
}
|
|
1344
1374
|
break;
|
|
1345
1375
|
case ReactMultiChildUpdateTypes.SET_MARKUP:
|
|
1346
1376
|
setInnerHTML(parentNode, update.content);
|
|
1377
|
+
if ("development" !== 'production') {
|
|
1378
|
+
ReactInstrumentation.debugTool.onNativeOperation(parentNodeDebugID, 'replace children', update.content.toString());
|
|
1379
|
+
}
|
|
1347
1380
|
break;
|
|
1348
1381
|
case ReactMultiChildUpdateTypes.TEXT_CONTENT:
|
|
1349
1382
|
setTextContent(parentNode, update.content);
|
|
1383
|
+
if ("development" !== 'production') {
|
|
1384
|
+
ReactInstrumentation.debugTool.onNativeOperation(parentNodeDebugID, 'replace text', update.content.toString());
|
|
1385
|
+
}
|
|
1350
1386
|
break;
|
|
1351
1387
|
case ReactMultiChildUpdateTypes.REMOVE_NODE:
|
|
1352
1388
|
removeChild(parentNode, update.fromNode);
|
|
1389
|
+
if ("development" !== 'production') {
|
|
1390
|
+
ReactInstrumentation.debugTool.onNativeOperation(parentNodeDebugID, 'remove child', { fromIndex: update.fromIndex });
|
|
1391
|
+
}
|
|
1353
1392
|
break;
|
|
1354
1393
|
}
|
|
1355
1394
|
}
|
|
@@ -1357,12 +1396,8 @@ var DOMChildrenOperations = {
|
|
|
1357
1396
|
|
|
1358
1397
|
};
|
|
1359
1398
|
|
|
1360
|
-
ReactPerf.measureMethods(DOMChildrenOperations, 'DOMChildrenOperations', {
|
|
1361
|
-
replaceDelimitedText: 'replaceDelimitedText'
|
|
1362
|
-
});
|
|
1363
|
-
|
|
1364
1399
|
module.exports = DOMChildrenOperations;
|
|
1365
|
-
},{"12":12,"129":129,"150":150,"151":151,"
|
|
1400
|
+
},{"12":12,"129":129,"150":150,"151":151,"45":45,"76":76,"8":8,"82":82}],8:[function(_dereq_,module,exports){
|
|
1366
1401
|
/**
|
|
1367
1402
|
* Copyright 2015-present, Facebook, Inc.
|
|
1368
1403
|
* All rights reserved.
|
|
@@ -1376,9 +1411,14 @@ module.exports = DOMChildrenOperations;
|
|
|
1376
1411
|
|
|
1377
1412
|
'use strict';
|
|
1378
1413
|
|
|
1414
|
+
var DOMNamespaces = _dereq_(9);
|
|
1415
|
+
|
|
1379
1416
|
var createMicrosoftUnsafeLocalFunction = _dereq_(129);
|
|
1380
1417
|
var setTextContent = _dereq_(151);
|
|
1381
1418
|
|
|
1419
|
+
var ELEMENT_NODE_TYPE = 1;
|
|
1420
|
+
var DOCUMENT_FRAGMENT_NODE_TYPE = 11;
|
|
1421
|
+
|
|
1382
1422
|
/**
|
|
1383
1423
|
* In IE (8-11) and Edge, appending nodes with no children is dramatically
|
|
1384
1424
|
* faster than appending a full subtree, so we essentially queue up the
|
|
@@ -1413,8 +1453,10 @@ var insertTreeBefore = createMicrosoftUnsafeLocalFunction(function (parentNode,
|
|
|
1413
1453
|
// DocumentFragments aren't actually part of the DOM after insertion so
|
|
1414
1454
|
// appending children won't update the DOM. We need to ensure the fragment
|
|
1415
1455
|
// is properly populated first, breaking out of our lazy approach for just
|
|
1416
|
-
// this level.
|
|
1417
|
-
|
|
1456
|
+
// this level. Also, some <object> plugins (like Flash Player) will read
|
|
1457
|
+
// <param> nodes immediately upon insertion into the DOM, so <object>
|
|
1458
|
+
// must also be populated prior to insertion into the DOM.
|
|
1459
|
+
if (tree.node.nodeType === DOCUMENT_FRAGMENT_NODE_TYPE || tree.node.nodeType === ELEMENT_NODE_TYPE && tree.node.nodeName.toLowerCase() === 'object' && (tree.node.namespaceURI == null || tree.node.namespaceURI === DOMNamespaces.html)) {
|
|
1418
1460
|
insertTreeChildren(tree);
|
|
1419
1461
|
parentNode.insertBefore(tree.node, referenceNode);
|
|
1420
1462
|
} else {
|
|
@@ -1452,12 +1494,17 @@ function queueText(tree, text) {
|
|
|
1452
1494
|
}
|
|
1453
1495
|
}
|
|
1454
1496
|
|
|
1497
|
+
function toString() {
|
|
1498
|
+
return this.node.nodeName;
|
|
1499
|
+
}
|
|
1500
|
+
|
|
1455
1501
|
function DOMLazyTree(node) {
|
|
1456
1502
|
return {
|
|
1457
1503
|
node: node,
|
|
1458
1504
|
children: [],
|
|
1459
1505
|
html: null,
|
|
1460
|
-
text: null
|
|
1506
|
+
text: null,
|
|
1507
|
+
toString: toString
|
|
1461
1508
|
};
|
|
1462
1509
|
}
|
|
1463
1510
|
|
|
@@ -1468,7 +1515,7 @@ DOMLazyTree.queueHTML = queueHTML;
|
|
|
1468
1515
|
DOMLazyTree.queueText = queueText;
|
|
1469
1516
|
|
|
1470
1517
|
module.exports = DOMLazyTree;
|
|
1471
|
-
},{"129":129,"151":151}],9:[function(_dereq_,module,exports){
|
|
1518
|
+
},{"129":129,"151":151,"9":9}],9:[function(_dereq_,module,exports){
|
|
1472
1519
|
/**
|
|
1473
1520
|
* Copyright 2013-present, Facebook, Inc.
|
|
1474
1521
|
* All rights reserved.
|
|
@@ -1718,8 +1765,9 @@ module.exports = DOMProperty;
|
|
|
1718
1765
|
'use strict';
|
|
1719
1766
|
|
|
1720
1767
|
var DOMProperty = _dereq_(10);
|
|
1721
|
-
var
|
|
1722
|
-
var
|
|
1768
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
1769
|
+
var ReactDOMInstrumentation = _dereq_(53);
|
|
1770
|
+
var ReactInstrumentation = _dereq_(76);
|
|
1723
1771
|
|
|
1724
1772
|
var quoteAttributeValueForBrowser = _dereq_(148);
|
|
1725
1773
|
var warning = _dereq_(183);
|
|
@@ -1827,9 +1875,6 @@ var DOMPropertyOperations = {
|
|
|
1827
1875
|
* @param {*} value
|
|
1828
1876
|
*/
|
|
1829
1877
|
setValueForProperty: function (node, name, value) {
|
|
1830
|
-
if ("development" !== 'production') {
|
|
1831
|
-
ReactDOMInstrumentation.debugTool.onSetValueForProperty(node, name, value);
|
|
1832
|
-
}
|
|
1833
1878
|
var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null;
|
|
1834
1879
|
if (propertyInfo) {
|
|
1835
1880
|
var mutationMethod = propertyInfo.mutationMethod;
|
|
@@ -1837,6 +1882,7 @@ var DOMPropertyOperations = {
|
|
|
1837
1882
|
mutationMethod(node, value);
|
|
1838
1883
|
} else if (shouldIgnoreValue(propertyInfo, value)) {
|
|
1839
1884
|
this.deleteValueForProperty(node, name);
|
|
1885
|
+
return;
|
|
1840
1886
|
} else if (propertyInfo.mustUseProperty) {
|
|
1841
1887
|
var propName = propertyInfo.propertyName;
|
|
1842
1888
|
// Must explicitly cast values for HAS_SIDE_EFFECTS-properties to the
|
|
@@ -1861,6 +1907,14 @@ var DOMPropertyOperations = {
|
|
|
1861
1907
|
}
|
|
1862
1908
|
} else if (DOMProperty.isCustomAttribute(name)) {
|
|
1863
1909
|
DOMPropertyOperations.setValueForAttribute(node, name, value);
|
|
1910
|
+
return;
|
|
1911
|
+
}
|
|
1912
|
+
|
|
1913
|
+
if ("development" !== 'production') {
|
|
1914
|
+
ReactDOMInstrumentation.debugTool.onSetValueForProperty(node, name, value);
|
|
1915
|
+
var payload = {};
|
|
1916
|
+
payload[name] = value;
|
|
1917
|
+
ReactInstrumentation.debugTool.onNativeOperation(ReactDOMComponentTree.getInstanceFromNode(node)._debugID, 'update attribute', payload);
|
|
1864
1918
|
}
|
|
1865
1919
|
},
|
|
1866
1920
|
|
|
@@ -1873,6 +1927,12 @@ var DOMPropertyOperations = {
|
|
|
1873
1927
|
} else {
|
|
1874
1928
|
node.setAttribute(name, '' + value);
|
|
1875
1929
|
}
|
|
1930
|
+
|
|
1931
|
+
if ("development" !== 'production') {
|
|
1932
|
+
var payload = {};
|
|
1933
|
+
payload[name] = value;
|
|
1934
|
+
ReactInstrumentation.debugTool.onNativeOperation(ReactDOMComponentTree.getInstanceFromNode(node)._debugID, 'update attribute', payload);
|
|
1935
|
+
}
|
|
1876
1936
|
},
|
|
1877
1937
|
|
|
1878
1938
|
/**
|
|
@@ -1882,9 +1942,6 @@ var DOMPropertyOperations = {
|
|
|
1882
1942
|
* @param {string} name
|
|
1883
1943
|
*/
|
|
1884
1944
|
deleteValueForProperty: function (node, name) {
|
|
1885
|
-
if ("development" !== 'production') {
|
|
1886
|
-
ReactDOMInstrumentation.debugTool.onDeleteValueForProperty(node, name);
|
|
1887
|
-
}
|
|
1888
1945
|
var propertyInfo = DOMProperty.properties.hasOwnProperty(name) ? DOMProperty.properties[name] : null;
|
|
1889
1946
|
if (propertyInfo) {
|
|
1890
1947
|
var mutationMethod = propertyInfo.mutationMethod;
|
|
@@ -1906,18 +1963,17 @@ var DOMPropertyOperations = {
|
|
|
1906
1963
|
} else if (DOMProperty.isCustomAttribute(name)) {
|
|
1907
1964
|
node.removeAttribute(name);
|
|
1908
1965
|
}
|
|
1966
|
+
|
|
1967
|
+
if ("development" !== 'production') {
|
|
1968
|
+
ReactDOMInstrumentation.debugTool.onDeleteValueForProperty(node, name);
|
|
1969
|
+
ReactInstrumentation.debugTool.onNativeOperation(ReactDOMComponentTree.getInstanceFromNode(node)._debugID, 'remove attribute', name);
|
|
1970
|
+
}
|
|
1909
1971
|
}
|
|
1910
1972
|
|
|
1911
1973
|
};
|
|
1912
1974
|
|
|
1913
|
-
ReactPerf.measureMethods(DOMPropertyOperations, 'DOMPropertyOperations', {
|
|
1914
|
-
setValueForProperty: 'setValueForProperty',
|
|
1915
|
-
setValueForAttribute: 'setValueForAttribute',
|
|
1916
|
-
deleteValueForProperty: 'deleteValueForProperty'
|
|
1917
|
-
});
|
|
1918
|
-
|
|
1919
1975
|
module.exports = DOMPropertyOperations;
|
|
1920
|
-
},{"10":10,"148":148,"183":183,"
|
|
1976
|
+
},{"10":10,"148":148,"183":183,"45":45,"53":53,"76":76}],12:[function(_dereq_,module,exports){
|
|
1921
1977
|
/**
|
|
1922
1978
|
* Copyright 2013-present, Facebook, Inc.
|
|
1923
1979
|
* All rights reserved.
|
|
@@ -2157,7 +2213,7 @@ module.exports = DisabledInputUtils;
|
|
|
2157
2213
|
|
|
2158
2214
|
var EventConstants = _dereq_(16);
|
|
2159
2215
|
var EventPropagators = _dereq_(20);
|
|
2160
|
-
var ReactDOMComponentTree = _dereq_(
|
|
2216
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
2161
2217
|
var SyntheticMouseEvent = _dereq_(119);
|
|
2162
2218
|
|
|
2163
2219
|
var keyOf = _dereq_(177);
|
|
@@ -2247,7 +2303,7 @@ var EnterLeaveEventPlugin = {
|
|
|
2247
2303
|
};
|
|
2248
2304
|
|
|
2249
2305
|
module.exports = EnterLeaveEventPlugin;
|
|
2250
|
-
},{"119":119,"16":16,"177":177,"20":20,"
|
|
2306
|
+
},{"119":119,"16":16,"177":177,"20":20,"45":45}],16:[function(_dereq_,module,exports){
|
|
2251
2307
|
/**
|
|
2252
2308
|
* Copyright 2013-present, Facebook, Inc.
|
|
2253
2309
|
* All rights reserved.
|
|
@@ -2361,7 +2417,7 @@ module.exports = EventConstants;
|
|
|
2361
2417
|
|
|
2362
2418
|
var EventPluginRegistry = _dereq_(18);
|
|
2363
2419
|
var EventPluginUtils = _dereq_(19);
|
|
2364
|
-
var ReactErrorUtils = _dereq_(
|
|
2420
|
+
var ReactErrorUtils = _dereq_(68);
|
|
2365
2421
|
|
|
2366
2422
|
var accumulateInto = _dereq_(126);
|
|
2367
2423
|
var forEachAccumulated = _dereq_(134);
|
|
@@ -2581,7 +2637,7 @@ var EventPluginHub = {
|
|
|
2581
2637
|
};
|
|
2582
2638
|
|
|
2583
2639
|
module.exports = EventPluginHub;
|
|
2584
|
-
},{"126":126,"134":134,"173":173,"18":18,"19":19,"
|
|
2640
|
+
},{"126":126,"134":134,"173":173,"18":18,"19":19,"68":68}],18:[function(_dereq_,module,exports){
|
|
2585
2641
|
/**
|
|
2586
2642
|
* Copyright 2013-present, Facebook, Inc.
|
|
2587
2643
|
* All rights reserved.
|
|
@@ -2838,7 +2894,7 @@ module.exports = EventPluginRegistry;
|
|
|
2838
2894
|
'use strict';
|
|
2839
2895
|
|
|
2840
2896
|
var EventConstants = _dereq_(16);
|
|
2841
|
-
var ReactErrorUtils = _dereq_(
|
|
2897
|
+
var ReactErrorUtils = _dereq_(68);
|
|
2842
2898
|
|
|
2843
2899
|
var invariant = _dereq_(173);
|
|
2844
2900
|
var warning = _dereq_(183);
|
|
@@ -3051,7 +3107,7 @@ var EventPluginUtils = {
|
|
|
3051
3107
|
};
|
|
3052
3108
|
|
|
3053
3109
|
module.exports = EventPluginUtils;
|
|
3054
|
-
},{"16":16,"173":173,"183":183,"
|
|
3110
|
+
},{"16":16,"173":173,"183":183,"68":68}],20:[function(_dereq_,module,exports){
|
|
3055
3111
|
/**
|
|
3056
3112
|
* Copyright 2013-present, Facebook, Inc.
|
|
3057
3113
|
* All rights reserved.
|
|
@@ -3568,11 +3624,12 @@ module.exports = KeyEscapeUtils;
|
|
|
3568
3624
|
|
|
3569
3625
|
'use strict';
|
|
3570
3626
|
|
|
3571
|
-
var ReactLink = _dereq_(
|
|
3627
|
+
var ReactLink = _dereq_(78);
|
|
3572
3628
|
var ReactStateSetters = _dereq_(98);
|
|
3573
3629
|
|
|
3574
3630
|
/**
|
|
3575
3631
|
* A simple mixin around ReactLink.forState().
|
|
3632
|
+
* See https://facebook.github.io/react/docs/two-way-binding-helpers.html
|
|
3576
3633
|
*/
|
|
3577
3634
|
var LinkedStateMixin = {
|
|
3578
3635
|
/**
|
|
@@ -3590,7 +3647,7 @@ var LinkedStateMixin = {
|
|
|
3590
3647
|
};
|
|
3591
3648
|
|
|
3592
3649
|
module.exports = LinkedStateMixin;
|
|
3593
|
-
},{"
|
|
3650
|
+
},{"78":78,"98":98}],25:[function(_dereq_,module,exports){
|
|
3594
3651
|
/**
|
|
3595
3652
|
* Copyright 2013-present, Facebook, Inc.
|
|
3596
3653
|
* All rights reserved.
|
|
@@ -3863,9 +3920,9 @@ var _assign = _dereq_(184);
|
|
|
3863
3920
|
var ReactChildren = _dereq_(32);
|
|
3864
3921
|
var ReactComponent = _dereq_(34);
|
|
3865
3922
|
var ReactClass = _dereq_(33);
|
|
3866
|
-
var ReactDOMFactories = _dereq_(
|
|
3867
|
-
var ReactElement = _dereq_(
|
|
3868
|
-
var ReactElementValidator = _dereq_(
|
|
3923
|
+
var ReactDOMFactories = _dereq_(49);
|
|
3924
|
+
var ReactElement = _dereq_(65);
|
|
3925
|
+
var ReactElementValidator = _dereq_(66);
|
|
3869
3926
|
var ReactPropTypes = _dereq_(91);
|
|
3870
3927
|
var ReactVersion = _dereq_(105);
|
|
3871
3928
|
|
|
@@ -3932,7 +3989,7 @@ var React = {
|
|
|
3932
3989
|
};
|
|
3933
3990
|
|
|
3934
3991
|
module.exports = React;
|
|
3935
|
-
},{"105":105,"147":147,"183":183,"184":184,"32":32,"33":33,"34":34,"
|
|
3992
|
+
},{"105":105,"147":147,"183":183,"184":184,"32":32,"33":33,"34":34,"49":49,"65":65,"66":66,"91":91}],28:[function(_dereq_,module,exports){
|
|
3936
3993
|
/**
|
|
3937
3994
|
* Copyright 2013-present, Facebook, Inc.
|
|
3938
3995
|
* All rights reserved.
|
|
@@ -3950,7 +4007,7 @@ var _assign = _dereq_(184);
|
|
|
3950
4007
|
|
|
3951
4008
|
var EventConstants = _dereq_(16);
|
|
3952
4009
|
var EventPluginRegistry = _dereq_(18);
|
|
3953
|
-
var ReactEventEmitterMixin = _dereq_(
|
|
4010
|
+
var ReactEventEmitterMixin = _dereq_(69);
|
|
3954
4011
|
var ViewportMetrics = _dereq_(125);
|
|
3955
4012
|
|
|
3956
4013
|
var getVendorPrefixedEventName = _dereq_(143);
|
|
@@ -4250,7 +4307,7 @@ var ReactBrowserEventEmitter = _assign({}, ReactEventEmitterMixin, {
|
|
|
4250
4307
|
});
|
|
4251
4308
|
|
|
4252
4309
|
module.exports = ReactBrowserEventEmitter;
|
|
4253
|
-
},{"125":125,"143":143,"145":145,"16":16,"18":18,"184":184,"
|
|
4310
|
+
},{"125":125,"143":143,"145":145,"16":16,"18":18,"184":184,"69":69}],29:[function(_dereq_,module,exports){
|
|
4254
4311
|
/**
|
|
4255
4312
|
* Copyright 2013-present, Facebook, Inc.
|
|
4256
4313
|
* All rights reserved.
|
|
@@ -4290,6 +4347,11 @@ function createTransitionTimeoutPropValidator(transitionType) {
|
|
|
4290
4347
|
};
|
|
4291
4348
|
}
|
|
4292
4349
|
|
|
4350
|
+
/**
|
|
4351
|
+
* An easy way to perform CSS transitions and animations when a React component
|
|
4352
|
+
* enters or leaves the DOM.
|
|
4353
|
+
* See https://facebook.github.io/react/docs/animation.html#high-level-api-reactcsstransitiongroup
|
|
4354
|
+
*/
|
|
4293
4355
|
var ReactCSSTransitionGroup = React.createClass({
|
|
4294
4356
|
displayName: 'ReactCSSTransitionGroup',
|
|
4295
4357
|
|
|
@@ -4348,7 +4410,7 @@ module.exports = ReactCSSTransitionGroup;
|
|
|
4348
4410
|
'use strict';
|
|
4349
4411
|
|
|
4350
4412
|
var React = _dereq_(27);
|
|
4351
|
-
var ReactDOM = _dereq_(
|
|
4413
|
+
var ReactDOM = _dereq_(41);
|
|
4352
4414
|
|
|
4353
4415
|
var CSSCore = _dereq_(157);
|
|
4354
4416
|
var ReactTransitionEvents = _dereq_(101);
|
|
@@ -4494,7 +4556,7 @@ var ReactCSSTransitionGroupChild = React.createClass({
|
|
|
4494
4556
|
});
|
|
4495
4557
|
|
|
4496
4558
|
module.exports = ReactCSSTransitionGroupChild;
|
|
4497
|
-
},{"101":101,"147":147,"157":157,"27":27,"
|
|
4559
|
+
},{"101":101,"147":147,"157":157,"27":27,"41":41}],31:[function(_dereq_,module,exports){
|
|
4498
4560
|
/**
|
|
4499
4561
|
* Copyright 2014-present, Facebook, Inc.
|
|
4500
4562
|
* All rights reserved.
|
|
@@ -4635,7 +4697,7 @@ module.exports = ReactChildReconciler;
|
|
|
4635
4697
|
'use strict';
|
|
4636
4698
|
|
|
4637
4699
|
var PooledClass = _dereq_(26);
|
|
4638
|
-
var ReactElement = _dereq_(
|
|
4700
|
+
var ReactElement = _dereq_(65);
|
|
4639
4701
|
|
|
4640
4702
|
var emptyFunction = _dereq_(165);
|
|
4641
4703
|
var traverseAllChildren = _dereq_(154);
|
|
@@ -4678,6 +4740,8 @@ function forEachSingleChild(bookKeeping, child, name) {
|
|
|
4678
4740
|
/**
|
|
4679
4741
|
* Iterates through children that are typically specified as `props.children`.
|
|
4680
4742
|
*
|
|
4743
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.children.foreach
|
|
4744
|
+
*
|
|
4681
4745
|
* The provided forEachFunc(child, index) will be called for each
|
|
4682
4746
|
* leaf child.
|
|
4683
4747
|
*
|
|
@@ -4753,7 +4817,9 @@ function mapIntoWithKeyPrefixInternal(children, array, prefix, func, context) {
|
|
|
4753
4817
|
/**
|
|
4754
4818
|
* Maps children that are typically specified as `props.children`.
|
|
4755
4819
|
*
|
|
4756
|
-
*
|
|
4820
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.children.map
|
|
4821
|
+
*
|
|
4822
|
+
* The provided mapFunction(child, key, index) will be called for each
|
|
4757
4823
|
* leaf child.
|
|
4758
4824
|
*
|
|
4759
4825
|
* @param {?*} children Children tree container.
|
|
@@ -4778,6 +4844,8 @@ function forEachSingleChildDummy(traverseContext, child, name) {
|
|
|
4778
4844
|
* Count the number of children that are typically specified as
|
|
4779
4845
|
* `props.children`.
|
|
4780
4846
|
*
|
|
4847
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.children.count
|
|
4848
|
+
*
|
|
4781
4849
|
* @param {?*} children Children tree container.
|
|
4782
4850
|
* @return {number} The number of children.
|
|
4783
4851
|
*/
|
|
@@ -4788,6 +4856,8 @@ function countChildren(children, context) {
|
|
|
4788
4856
|
/**
|
|
4789
4857
|
* Flatten a children object (typically specified as `props.children`) and
|
|
4790
4858
|
* return an array with appropriately re-keyed children.
|
|
4859
|
+
*
|
|
4860
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.children.toarray
|
|
4791
4861
|
*/
|
|
4792
4862
|
function toArray(children) {
|
|
4793
4863
|
var result = [];
|
|
@@ -4804,7 +4874,7 @@ var ReactChildren = {
|
|
|
4804
4874
|
};
|
|
4805
4875
|
|
|
4806
4876
|
module.exports = ReactChildren;
|
|
4807
|
-
},{"154":154,"165":165,"26":26,"
|
|
4877
|
+
},{"154":154,"165":165,"26":26,"65":65}],33:[function(_dereq_,module,exports){
|
|
4808
4878
|
/**
|
|
4809
4879
|
* Copyright 2013-present, Facebook, Inc.
|
|
4810
4880
|
* All rights reserved.
|
|
@@ -4821,7 +4891,7 @@ module.exports = ReactChildren;
|
|
|
4821
4891
|
var _assign = _dereq_(184);
|
|
4822
4892
|
|
|
4823
4893
|
var ReactComponent = _dereq_(34);
|
|
4824
|
-
var ReactElement = _dereq_(
|
|
4894
|
+
var ReactElement = _dereq_(65);
|
|
4825
4895
|
var ReactPropTypeLocations = _dereq_(90);
|
|
4826
4896
|
var ReactPropTypeLocationNames = _dereq_(89);
|
|
4827
4897
|
var ReactNoopUpdateQueue = _dereq_(86);
|
|
@@ -5434,6 +5504,7 @@ var ReactClass = {
|
|
|
5434
5504
|
|
|
5435
5505
|
/**
|
|
5436
5506
|
* Creates a composite component class given a class specification.
|
|
5507
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.createclass
|
|
5437
5508
|
*
|
|
5438
5509
|
* @param {object} spec Class specification (which must define `render`).
|
|
5439
5510
|
* @return {function} Component constructor function.
|
|
@@ -5528,7 +5599,7 @@ var ReactClass = {
|
|
|
5528
5599
|
};
|
|
5529
5600
|
|
|
5530
5601
|
module.exports = ReactClass;
|
|
5531
|
-
},{"166":166,"173":173,"176":176,"177":177,"183":183,"184":184,"34":34,"
|
|
5602
|
+
},{"166":166,"173":173,"176":176,"177":177,"183":183,"184":184,"34":34,"65":65,"86":86,"89":89,"90":90}],34:[function(_dereq_,module,exports){
|
|
5532
5603
|
/**
|
|
5533
5604
|
* Copyright 2013-present, Facebook, Inc.
|
|
5534
5605
|
* All rights reserved.
|
|
@@ -5543,7 +5614,7 @@ module.exports = ReactClass;
|
|
|
5543
5614
|
'use strict';
|
|
5544
5615
|
|
|
5545
5616
|
var ReactNoopUpdateQueue = _dereq_(86);
|
|
5546
|
-
var ReactInstrumentation = _dereq_(
|
|
5617
|
+
var ReactInstrumentation = _dereq_(76);
|
|
5547
5618
|
|
|
5548
5619
|
var canDefineProperty = _dereq_(128);
|
|
5549
5620
|
var emptyObject = _dereq_(166);
|
|
@@ -5650,7 +5721,7 @@ if ("development" !== 'production') {
|
|
|
5650
5721
|
}
|
|
5651
5722
|
|
|
5652
5723
|
module.exports = ReactComponent;
|
|
5653
|
-
},{"128":128,"166":166,"173":173,"183":183,"
|
|
5724
|
+
},{"128":128,"166":166,"173":173,"183":183,"76":76,"86":86}],35:[function(_dereq_,module,exports){
|
|
5654
5725
|
/**
|
|
5655
5726
|
* Copyright 2013-present, Facebook, Inc.
|
|
5656
5727
|
* All rights reserved.
|
|
@@ -5665,8 +5736,7 @@ module.exports = ReactComponent;
|
|
|
5665
5736
|
'use strict';
|
|
5666
5737
|
|
|
5667
5738
|
var DOMChildrenOperations = _dereq_(7);
|
|
5668
|
-
var ReactDOMIDOperations = _dereq_(
|
|
5669
|
-
var ReactPerf = _dereq_(88);
|
|
5739
|
+
var ReactDOMIDOperations = _dereq_(51);
|
|
5670
5740
|
|
|
5671
5741
|
/**
|
|
5672
5742
|
* Abstracts away all functionality of the reconciler that requires knowledge of
|
|
@@ -5690,12 +5760,8 @@ var ReactComponentBrowserEnvironment = {
|
|
|
5690
5760
|
|
|
5691
5761
|
};
|
|
5692
5762
|
|
|
5693
|
-
ReactPerf.measureMethods(ReactComponentBrowserEnvironment, 'ReactComponentBrowserEnvironment', {
|
|
5694
|
-
replaceNodeWithMarkup: 'replaceNodeWithMarkup'
|
|
5695
|
-
});
|
|
5696
|
-
|
|
5697
5763
|
module.exports = ReactComponentBrowserEnvironment;
|
|
5698
|
-
},{"
|
|
5764
|
+
},{"51":51,"7":7}],36:[function(_dereq_,module,exports){
|
|
5699
5765
|
/**
|
|
5700
5766
|
* Copyright 2014-present, Facebook, Inc.
|
|
5701
5767
|
* All rights reserved.
|
|
@@ -5748,6 +5814,152 @@ var ReactComponentEnvironment = {
|
|
|
5748
5814
|
|
|
5749
5815
|
module.exports = ReactComponentEnvironment;
|
|
5750
5816
|
},{"173":173}],37:[function(_dereq_,module,exports){
|
|
5817
|
+
/**
|
|
5818
|
+
* Copyright 2016-present, Facebook, Inc.
|
|
5819
|
+
* All rights reserved.
|
|
5820
|
+
*
|
|
5821
|
+
* This source code is licensed under the BSD-style license found in the
|
|
5822
|
+
* LICENSE file in the root directory of this source tree. An additional grant
|
|
5823
|
+
* of patent rights can be found in the PATENTS file in the same directory.
|
|
5824
|
+
*
|
|
5825
|
+
* @providesModule ReactComponentTreeDevtool
|
|
5826
|
+
*/
|
|
5827
|
+
|
|
5828
|
+
'use strict';
|
|
5829
|
+
|
|
5830
|
+
var invariant = _dereq_(173);
|
|
5831
|
+
|
|
5832
|
+
var tree = {};
|
|
5833
|
+
var rootIDs = [];
|
|
5834
|
+
|
|
5835
|
+
function updateTree(id, update) {
|
|
5836
|
+
if (!tree[id]) {
|
|
5837
|
+
tree[id] = {
|
|
5838
|
+
parentID: null,
|
|
5839
|
+
ownerID: null,
|
|
5840
|
+
text: null,
|
|
5841
|
+
childIDs: [],
|
|
5842
|
+
displayName: 'Unknown',
|
|
5843
|
+
isMounted: false,
|
|
5844
|
+
updateCount: 0
|
|
5845
|
+
};
|
|
5846
|
+
}
|
|
5847
|
+
update(tree[id]);
|
|
5848
|
+
}
|
|
5849
|
+
|
|
5850
|
+
function purgeDeep(id) {
|
|
5851
|
+
var item = tree[id];
|
|
5852
|
+
if (item) {
|
|
5853
|
+
var childIDs = item.childIDs;
|
|
5854
|
+
|
|
5855
|
+
delete tree[id];
|
|
5856
|
+
childIDs.forEach(purgeDeep);
|
|
5857
|
+
}
|
|
5858
|
+
}
|
|
5859
|
+
|
|
5860
|
+
var ReactComponentTreeDevtool = {
|
|
5861
|
+
onSetDisplayName: function (id, displayName) {
|
|
5862
|
+
updateTree(id, function (item) {
|
|
5863
|
+
return item.displayName = displayName;
|
|
5864
|
+
});
|
|
5865
|
+
},
|
|
5866
|
+
onSetChildren: function (id, nextChildIDs) {
|
|
5867
|
+
updateTree(id, function (item) {
|
|
5868
|
+
var prevChildIDs = item.childIDs;
|
|
5869
|
+
item.childIDs = nextChildIDs;
|
|
5870
|
+
|
|
5871
|
+
nextChildIDs.forEach(function (nextChildID) {
|
|
5872
|
+
var nextChild = tree[nextChildID];
|
|
5873
|
+
!nextChild ? "development" !== 'production' ? invariant(false, 'Expected devtool events to fire for the child ' + 'before its parent includes it in onSetChildren().') : invariant(false) : void 0;
|
|
5874
|
+
!(nextChild.displayName != null) ? "development" !== 'production' ? invariant(false, 'Expected onSetDisplayName() to fire for the child ' + 'before its parent includes it in onSetChildren().') : invariant(false) : void 0;
|
|
5875
|
+
!(nextChild.childIDs != null || nextChild.text != null) ? "development" !== 'production' ? invariant(false, 'Expected onSetChildren() or onSetText() to fire for the child ' + 'before its parent includes it in onSetChildren().') : invariant(false) : void 0;
|
|
5876
|
+
!nextChild.isMounted ? "development" !== 'production' ? invariant(false, 'Expected onMountComponent() to fire for the child ' + 'before its parent includes it in onSetChildren().') : invariant(false) : void 0;
|
|
5877
|
+
|
|
5878
|
+
if (prevChildIDs.indexOf(nextChildID) === -1) {
|
|
5879
|
+
nextChild.parentID = id;
|
|
5880
|
+
}
|
|
5881
|
+
});
|
|
5882
|
+
});
|
|
5883
|
+
},
|
|
5884
|
+
onSetOwner: function (id, ownerID) {
|
|
5885
|
+
updateTree(id, function (item) {
|
|
5886
|
+
return item.ownerID = ownerID;
|
|
5887
|
+
});
|
|
5888
|
+
},
|
|
5889
|
+
onSetText: function (id, text) {
|
|
5890
|
+
updateTree(id, function (item) {
|
|
5891
|
+
return item.text = text;
|
|
5892
|
+
});
|
|
5893
|
+
},
|
|
5894
|
+
onMountComponent: function (id) {
|
|
5895
|
+
updateTree(id, function (item) {
|
|
5896
|
+
return item.isMounted = true;
|
|
5897
|
+
});
|
|
5898
|
+
},
|
|
5899
|
+
onMountRootComponent: function (id) {
|
|
5900
|
+
rootIDs.push(id);
|
|
5901
|
+
},
|
|
5902
|
+
onUpdateComponent: function (id) {
|
|
5903
|
+
updateTree(id, function (item) {
|
|
5904
|
+
return item.updateCount++;
|
|
5905
|
+
});
|
|
5906
|
+
},
|
|
5907
|
+
onUnmountComponent: function (id) {
|
|
5908
|
+
updateTree(id, function (item) {
|
|
5909
|
+
return item.isMounted = false;
|
|
5910
|
+
});
|
|
5911
|
+
rootIDs = rootIDs.filter(function (rootID) {
|
|
5912
|
+
return rootID !== id;
|
|
5913
|
+
});
|
|
5914
|
+
},
|
|
5915
|
+
purgeUnmountedComponents: function () {
|
|
5916
|
+
if (ReactComponentTreeDevtool._preventPurging) {
|
|
5917
|
+
// Should only be used for testing.
|
|
5918
|
+
return;
|
|
5919
|
+
}
|
|
5920
|
+
|
|
5921
|
+
Object.keys(tree).filter(function (id) {
|
|
5922
|
+
return !tree[id].isMounted;
|
|
5923
|
+
}).forEach(purgeDeep);
|
|
5924
|
+
},
|
|
5925
|
+
isMounted: function (id) {
|
|
5926
|
+
var item = tree[id];
|
|
5927
|
+
return item ? item.isMounted : false;
|
|
5928
|
+
},
|
|
5929
|
+
getChildIDs: function (id) {
|
|
5930
|
+
var item = tree[id];
|
|
5931
|
+
return item ? item.childIDs : [];
|
|
5932
|
+
},
|
|
5933
|
+
getDisplayName: function (id) {
|
|
5934
|
+
var item = tree[id];
|
|
5935
|
+
return item ? item.displayName : 'Unknown';
|
|
5936
|
+
},
|
|
5937
|
+
getOwnerID: function (id) {
|
|
5938
|
+
var item = tree[id];
|
|
5939
|
+
return item ? item.ownerID : null;
|
|
5940
|
+
},
|
|
5941
|
+
getParentID: function (id) {
|
|
5942
|
+
var item = tree[id];
|
|
5943
|
+
return item ? item.parentID : null;
|
|
5944
|
+
},
|
|
5945
|
+
getText: function (id) {
|
|
5946
|
+
var item = tree[id];
|
|
5947
|
+
return item ? item.text : null;
|
|
5948
|
+
},
|
|
5949
|
+
getUpdateCount: function (id) {
|
|
5950
|
+
var item = tree[id];
|
|
5951
|
+
return item ? item.updateCount : 0;
|
|
5952
|
+
},
|
|
5953
|
+
getRootIDs: function () {
|
|
5954
|
+
return rootIDs;
|
|
5955
|
+
},
|
|
5956
|
+
getRegisteredIDs: function () {
|
|
5957
|
+
return Object.keys(tree);
|
|
5958
|
+
}
|
|
5959
|
+
};
|
|
5960
|
+
|
|
5961
|
+
module.exports = ReactComponentTreeDevtool;
|
|
5962
|
+
},{"173":173}],38:[function(_dereq_,module,exports){
|
|
5751
5963
|
/**
|
|
5752
5964
|
* Copyright 2013-present, Facebook, Inc.
|
|
5753
5965
|
* All rights reserved.
|
|
@@ -5786,6 +5998,8 @@ var shallowCompare = _dereq_(152);
|
|
|
5786
5998
|
* complex data structures this mixin may have false-negatives for deeper
|
|
5787
5999
|
* differences. Only mixin to components which have simple props and state, or
|
|
5788
6000
|
* use `forceUpdate()` when you know deep data structures have changed.
|
|
6001
|
+
*
|
|
6002
|
+
* See https://facebook.github.io/react/docs/pure-render-mixin.html
|
|
5789
6003
|
*/
|
|
5790
6004
|
var ReactComponentWithPureRenderMixin = {
|
|
5791
6005
|
shouldComponentUpdate: function (nextProps, nextState) {
|
|
@@ -5794,7 +6008,7 @@ var ReactComponentWithPureRenderMixin = {
|
|
|
5794
6008
|
};
|
|
5795
6009
|
|
|
5796
6010
|
module.exports = ReactComponentWithPureRenderMixin;
|
|
5797
|
-
},{"152":152}],
|
|
6011
|
+
},{"152":152}],39:[function(_dereq_,module,exports){
|
|
5798
6012
|
/**
|
|
5799
6013
|
* Copyright 2013-present, Facebook, Inc.
|
|
5800
6014
|
* All rights reserved.
|
|
@@ -5811,13 +6025,12 @@ module.exports = ReactComponentWithPureRenderMixin;
|
|
|
5811
6025
|
var _assign = _dereq_(184);
|
|
5812
6026
|
|
|
5813
6027
|
var ReactComponentEnvironment = _dereq_(36);
|
|
5814
|
-
var ReactCurrentOwner = _dereq_(
|
|
5815
|
-
var ReactElement = _dereq_(
|
|
5816
|
-
var ReactErrorUtils = _dereq_(
|
|
5817
|
-
var ReactInstanceMap = _dereq_(
|
|
5818
|
-
var ReactInstrumentation = _dereq_(
|
|
6028
|
+
var ReactCurrentOwner = _dereq_(40);
|
|
6029
|
+
var ReactElement = _dereq_(65);
|
|
6030
|
+
var ReactErrorUtils = _dereq_(68);
|
|
6031
|
+
var ReactInstanceMap = _dereq_(75);
|
|
6032
|
+
var ReactInstrumentation = _dereq_(76);
|
|
5819
6033
|
var ReactNodeTypes = _dereq_(85);
|
|
5820
|
-
var ReactPerf = _dereq_(88);
|
|
5821
6034
|
var ReactPropTypeLocations = _dereq_(90);
|
|
5822
6035
|
var ReactPropTypeLocationNames = _dereq_(89);
|
|
5823
6036
|
var ReactReconciler = _dereq_(93);
|
|
@@ -5853,6 +6066,28 @@ function warnIfInvalidElement(Component, element) {
|
|
|
5853
6066
|
}
|
|
5854
6067
|
}
|
|
5855
6068
|
|
|
6069
|
+
function invokeComponentDidMountWithTimer() {
|
|
6070
|
+
var publicInstance = this._instance;
|
|
6071
|
+
if (this._debugID !== 0) {
|
|
6072
|
+
ReactInstrumentation.debugTool.onBeginLifeCycleTimer(this._debugID, 'componentDidMount');
|
|
6073
|
+
}
|
|
6074
|
+
publicInstance.componentDidMount();
|
|
6075
|
+
if (this._debugID !== 0) {
|
|
6076
|
+
ReactInstrumentation.debugTool.onEndLifeCycleTimer(this._debugID, 'componentDidMount');
|
|
6077
|
+
}
|
|
6078
|
+
}
|
|
6079
|
+
|
|
6080
|
+
function invokeComponentDidUpdateWithTimer(prevProps, prevState, prevContext) {
|
|
6081
|
+
var publicInstance = this._instance;
|
|
6082
|
+
if (this._debugID !== 0) {
|
|
6083
|
+
ReactInstrumentation.debugTool.onBeginLifeCycleTimer(this._debugID, 'componentDidUpdate');
|
|
6084
|
+
}
|
|
6085
|
+
publicInstance.componentDidUpdate(prevProps, prevState, prevContext);
|
|
6086
|
+
if (this._debugID !== 0) {
|
|
6087
|
+
ReactInstrumentation.debugTool.onEndLifeCycleTimer(this._debugID, 'componentDidUpdate');
|
|
6088
|
+
}
|
|
6089
|
+
}
|
|
6090
|
+
|
|
5856
6091
|
function shouldConstruct(Component) {
|
|
5857
6092
|
return Component.prototype && Component.prototype.isReactComponent;
|
|
5858
6093
|
}
|
|
@@ -5912,6 +6147,7 @@ var ReactCompositeComponentMixin = {
|
|
|
5912
6147
|
this._nativeContainerInfo = null;
|
|
5913
6148
|
|
|
5914
6149
|
// See ReactUpdateQueue
|
|
6150
|
+
this._updateBatchNumber = null;
|
|
5915
6151
|
this._pendingElement = null;
|
|
5916
6152
|
this._pendingStateQueue = null;
|
|
5917
6153
|
this._pendingReplaceState = false;
|
|
@@ -6020,7 +6256,11 @@ var ReactCompositeComponentMixin = {
|
|
|
6020
6256
|
}
|
|
6021
6257
|
|
|
6022
6258
|
if (inst.componentDidMount) {
|
|
6023
|
-
|
|
6259
|
+
if ("development" !== 'production') {
|
|
6260
|
+
transaction.getReactMountReady().enqueue(invokeComponentDidMountWithTimer, this);
|
|
6261
|
+
} else {
|
|
6262
|
+
transaction.getReactMountReady().enqueue(inst.componentDidMount, inst);
|
|
6263
|
+
}
|
|
6024
6264
|
}
|
|
6025
6265
|
|
|
6026
6266
|
return markup;
|
|
@@ -6041,11 +6281,35 @@ var ReactCompositeComponentMixin = {
|
|
|
6041
6281
|
|
|
6042
6282
|
_constructComponentWithoutOwner: function (publicProps, publicContext) {
|
|
6043
6283
|
var Component = this._currentElement.type;
|
|
6284
|
+
var instanceOrElement;
|
|
6044
6285
|
if (shouldConstruct(Component)) {
|
|
6045
|
-
|
|
6286
|
+
if ("development" !== 'production') {
|
|
6287
|
+
if (this._debugID !== 0) {
|
|
6288
|
+
ReactInstrumentation.debugTool.onBeginLifeCycleTimer(this._debugID, 'ctor');
|
|
6289
|
+
}
|
|
6290
|
+
}
|
|
6291
|
+
instanceOrElement = new Component(publicProps, publicContext, ReactUpdateQueue);
|
|
6292
|
+
if ("development" !== 'production') {
|
|
6293
|
+
if (this._debugID !== 0) {
|
|
6294
|
+
ReactInstrumentation.debugTool.onEndLifeCycleTimer(this._debugID, 'ctor');
|
|
6295
|
+
}
|
|
6296
|
+
}
|
|
6046
6297
|
} else {
|
|
6047
|
-
|
|
6298
|
+
// This can still be an instance in case of factory components
|
|
6299
|
+
// but we'll count this as time spent rendering as the more common case.
|
|
6300
|
+
if ("development" !== 'production') {
|
|
6301
|
+
if (this._debugID !== 0) {
|
|
6302
|
+
ReactInstrumentation.debugTool.onBeginLifeCycleTimer(this._debugID, 'render');
|
|
6303
|
+
}
|
|
6304
|
+
}
|
|
6305
|
+
instanceOrElement = Component(publicProps, publicContext, ReactUpdateQueue);
|
|
6306
|
+
if ("development" !== 'production') {
|
|
6307
|
+
if (this._debugID !== 0) {
|
|
6308
|
+
ReactInstrumentation.debugTool.onEndLifeCycleTimer(this._debugID, 'render');
|
|
6309
|
+
}
|
|
6310
|
+
}
|
|
6048
6311
|
}
|
|
6312
|
+
return instanceOrElement;
|
|
6049
6313
|
},
|
|
6050
6314
|
|
|
6051
6315
|
performInitialMountWithErrorHandling: function (renderedElement, nativeParent, nativeContainerInfo, transaction, context) {
|
|
@@ -6075,7 +6339,17 @@ var ReactCompositeComponentMixin = {
|
|
|
6075
6339
|
performInitialMount: function (renderedElement, nativeParent, nativeContainerInfo, transaction, context) {
|
|
6076
6340
|
var inst = this._instance;
|
|
6077
6341
|
if (inst.componentWillMount) {
|
|
6342
|
+
if ("development" !== 'production') {
|
|
6343
|
+
if (this._debugID !== 0) {
|
|
6344
|
+
ReactInstrumentation.debugTool.onBeginLifeCycleTimer(this._debugID, 'componentWillMount');
|
|
6345
|
+
}
|
|
6346
|
+
}
|
|
6078
6347
|
inst.componentWillMount();
|
|
6348
|
+
if ("development" !== 'production') {
|
|
6349
|
+
if (this._debugID !== 0) {
|
|
6350
|
+
ReactInstrumentation.debugTool.onEndLifeCycleTimer(this._debugID, 'componentWillMount');
|
|
6351
|
+
}
|
|
6352
|
+
}
|
|
6079
6353
|
// When mounting, calls to `setState` by `componentWillMount` will set
|
|
6080
6354
|
// `this._pendingStateQueue` without triggering a re-render.
|
|
6081
6355
|
if (this._pendingStateQueue) {
|
|
@@ -6093,6 +6367,12 @@ var ReactCompositeComponentMixin = {
|
|
|
6093
6367
|
|
|
6094
6368
|
var markup = ReactReconciler.mountComponent(this._renderedComponent, transaction, nativeParent, nativeContainerInfo, this._processChildContext(context));
|
|
6095
6369
|
|
|
6370
|
+
if ("development" !== 'production') {
|
|
6371
|
+
if (this._debugID !== 0) {
|
|
6372
|
+
ReactInstrumentation.debugTool.onSetChildren(this._debugID, this._renderedComponent._debugID !== 0 ? [this._renderedComponent._debugID] : []);
|
|
6373
|
+
}
|
|
6374
|
+
}
|
|
6375
|
+
|
|
6096
6376
|
return markup;
|
|
6097
6377
|
},
|
|
6098
6378
|
|
|
@@ -6114,12 +6394,22 @@ var ReactCompositeComponentMixin = {
|
|
|
6114
6394
|
|
|
6115
6395
|
if (inst.componentWillUnmount && !inst._calledComponentWillUnmount) {
|
|
6116
6396
|
inst._calledComponentWillUnmount = true;
|
|
6397
|
+
if ("development" !== 'production') {
|
|
6398
|
+
if (this._debugID !== 0) {
|
|
6399
|
+
ReactInstrumentation.debugTool.onBeginLifeCycleTimer(this._debugID, 'componentWillUnmount');
|
|
6400
|
+
}
|
|
6401
|
+
}
|
|
6117
6402
|
if (safely) {
|
|
6118
6403
|
var name = this.getName() + '.componentWillUnmount()';
|
|
6119
6404
|
ReactErrorUtils.invokeGuardedCallback(name, inst.componentWillUnmount.bind(inst));
|
|
6120
6405
|
} else {
|
|
6121
6406
|
inst.componentWillUnmount();
|
|
6122
6407
|
}
|
|
6408
|
+
if ("development" !== 'production') {
|
|
6409
|
+
if (this._debugID !== 0) {
|
|
6410
|
+
ReactInstrumentation.debugTool.onEndLifeCycleTimer(this._debugID, 'componentWillUnmount');
|
|
6411
|
+
}
|
|
6412
|
+
}
|
|
6123
6413
|
}
|
|
6124
6414
|
|
|
6125
6415
|
if (this._renderedComponent) {
|
|
@@ -6302,10 +6592,10 @@ var ReactCompositeComponentMixin = {
|
|
|
6302
6592
|
performUpdateIfNecessary: function (transaction) {
|
|
6303
6593
|
if (this._pendingElement != null) {
|
|
6304
6594
|
ReactReconciler.receiveComponent(this, this._pendingElement, transaction, this._context);
|
|
6305
|
-
}
|
|
6306
|
-
|
|
6307
|
-
if (this._pendingStateQueue !== null || this._pendingForceUpdate) {
|
|
6595
|
+
} else if (this._pendingStateQueue !== null || this._pendingForceUpdate) {
|
|
6308
6596
|
this.updateComponent(transaction, this._currentElement, this._currentElement, this._context, this._context);
|
|
6597
|
+
} else {
|
|
6598
|
+
this._updateBatchNumber = null;
|
|
6309
6599
|
}
|
|
6310
6600
|
},
|
|
6311
6601
|
|
|
@@ -6352,17 +6642,41 @@ var ReactCompositeComponentMixin = {
|
|
|
6352
6642
|
// _pendingStateQueue which will ensure that any state updates gets
|
|
6353
6643
|
// immediately reconciled instead of waiting for the next batch.
|
|
6354
6644
|
if (willReceive && inst.componentWillReceiveProps) {
|
|
6645
|
+
if ("development" !== 'production') {
|
|
6646
|
+
if (this._debugID !== 0) {
|
|
6647
|
+
ReactInstrumentation.debugTool.onBeginLifeCycleTimer(this._debugID, 'componentWillReceiveProps');
|
|
6648
|
+
}
|
|
6649
|
+
}
|
|
6355
6650
|
inst.componentWillReceiveProps(nextProps, nextContext);
|
|
6651
|
+
if ("development" !== 'production') {
|
|
6652
|
+
if (this._debugID !== 0) {
|
|
6653
|
+
ReactInstrumentation.debugTool.onEndLifeCycleTimer(this._debugID, 'componentWillReceiveProps');
|
|
6654
|
+
}
|
|
6655
|
+
}
|
|
6356
6656
|
}
|
|
6357
6657
|
|
|
6358
6658
|
var nextState = this._processPendingState(nextProps, nextContext);
|
|
6659
|
+
var shouldUpdate = true;
|
|
6359
6660
|
|
|
6360
|
-
|
|
6661
|
+
if (!this._pendingForceUpdate && inst.shouldComponentUpdate) {
|
|
6662
|
+
if ("development" !== 'production') {
|
|
6663
|
+
if (this._debugID !== 0) {
|
|
6664
|
+
ReactInstrumentation.debugTool.onBeginLifeCycleTimer(this._debugID, 'shouldComponentUpdate');
|
|
6665
|
+
}
|
|
6666
|
+
}
|
|
6667
|
+
shouldUpdate = inst.shouldComponentUpdate(nextProps, nextState, nextContext);
|
|
6668
|
+
if ("development" !== 'production') {
|
|
6669
|
+
if (this._debugID !== 0) {
|
|
6670
|
+
ReactInstrumentation.debugTool.onEndLifeCycleTimer(this._debugID, 'shouldComponentUpdate');
|
|
6671
|
+
}
|
|
6672
|
+
}
|
|
6673
|
+
}
|
|
6361
6674
|
|
|
6362
6675
|
if ("development" !== 'production') {
|
|
6363
6676
|
"development" !== 'production' ? warning(shouldUpdate !== undefined, '%s.shouldComponentUpdate(): Returned undefined instead of a ' + 'boolean value. Make sure to return true or false.', this.getName() || 'ReactCompositeComponent') : void 0;
|
|
6364
6677
|
}
|
|
6365
6678
|
|
|
6679
|
+
this._updateBatchNumber = null;
|
|
6366
6680
|
if (shouldUpdate) {
|
|
6367
6681
|
this._pendingForceUpdate = false;
|
|
6368
6682
|
// Will set `this.props`, `this.state` and `this.context`.
|
|
@@ -6428,7 +6742,17 @@ var ReactCompositeComponentMixin = {
|
|
|
6428
6742
|
}
|
|
6429
6743
|
|
|
6430
6744
|
if (inst.componentWillUpdate) {
|
|
6745
|
+
if ("development" !== 'production') {
|
|
6746
|
+
if (this._debugID !== 0) {
|
|
6747
|
+
ReactInstrumentation.debugTool.onBeginLifeCycleTimer(this._debugID, 'componentWillUpdate');
|
|
6748
|
+
}
|
|
6749
|
+
}
|
|
6431
6750
|
inst.componentWillUpdate(nextProps, nextState, nextContext);
|
|
6751
|
+
if ("development" !== 'production') {
|
|
6752
|
+
if (this._debugID !== 0) {
|
|
6753
|
+
ReactInstrumentation.debugTool.onEndLifeCycleTimer(this._debugID, 'componentWillUpdate');
|
|
6754
|
+
}
|
|
6755
|
+
}
|
|
6432
6756
|
}
|
|
6433
6757
|
|
|
6434
6758
|
this._currentElement = nextElement;
|
|
@@ -6440,7 +6764,11 @@ var ReactCompositeComponentMixin = {
|
|
|
6440
6764
|
this._updateRenderedComponent(transaction, unmaskedContext);
|
|
6441
6765
|
|
|
6442
6766
|
if (hasComponentDidUpdate) {
|
|
6443
|
-
|
|
6767
|
+
if ("development" !== 'production') {
|
|
6768
|
+
transaction.getReactMountReady().enqueue(invokeComponentDidUpdateWithTimer.bind(this, prevProps, prevState, prevContext), this);
|
|
6769
|
+
} else {
|
|
6770
|
+
transaction.getReactMountReady().enqueue(inst.componentDidUpdate.bind(inst, prevProps, prevState, prevContext), inst);
|
|
6771
|
+
}
|
|
6444
6772
|
}
|
|
6445
6773
|
},
|
|
6446
6774
|
|
|
@@ -6462,8 +6790,16 @@ var ReactCompositeComponentMixin = {
|
|
|
6462
6790
|
|
|
6463
6791
|
this._renderedNodeType = ReactNodeTypes.getType(nextRenderedElement);
|
|
6464
6792
|
this._renderedComponent = this._instantiateReactComponent(nextRenderedElement);
|
|
6793
|
+
|
|
6465
6794
|
var nextMarkup = ReactReconciler.mountComponent(this._renderedComponent, transaction, this._nativeParent, this._nativeContainerInfo, this._processChildContext(context));
|
|
6466
|
-
|
|
6795
|
+
|
|
6796
|
+
if ("development" !== 'production') {
|
|
6797
|
+
if (this._debugID !== 0) {
|
|
6798
|
+
ReactInstrumentation.debugTool.onSetChildren(this._debugID, this._renderedComponent._debugID !== 0 ? [this._renderedComponent._debugID] : []);
|
|
6799
|
+
}
|
|
6800
|
+
}
|
|
6801
|
+
|
|
6802
|
+
this._replaceNodeWithMarkup(oldNativeNode, nextMarkup, prevComponentInstance);
|
|
6467
6803
|
}
|
|
6468
6804
|
},
|
|
6469
6805
|
|
|
@@ -6472,8 +6808,8 @@ var ReactCompositeComponentMixin = {
|
|
|
6472
6808
|
*
|
|
6473
6809
|
* @protected
|
|
6474
6810
|
*/
|
|
6475
|
-
_replaceNodeWithMarkup: function (oldNativeNode, nextMarkup) {
|
|
6476
|
-
ReactComponentEnvironment.replaceNodeWithMarkup(oldNativeNode, nextMarkup);
|
|
6811
|
+
_replaceNodeWithMarkup: function (oldNativeNode, nextMarkup, prevInstance) {
|
|
6812
|
+
ReactComponentEnvironment.replaceNodeWithMarkup(oldNativeNode, nextMarkup, prevInstance);
|
|
6477
6813
|
},
|
|
6478
6814
|
|
|
6479
6815
|
/**
|
|
@@ -6481,7 +6817,19 @@ var ReactCompositeComponentMixin = {
|
|
|
6481
6817
|
*/
|
|
6482
6818
|
_renderValidatedComponentWithoutOwnerOrContext: function () {
|
|
6483
6819
|
var inst = this._instance;
|
|
6820
|
+
|
|
6821
|
+
if ("development" !== 'production') {
|
|
6822
|
+
if (this._debugID !== 0) {
|
|
6823
|
+
ReactInstrumentation.debugTool.onBeginLifeCycleTimer(this._debugID, 'render');
|
|
6824
|
+
}
|
|
6825
|
+
}
|
|
6484
6826
|
var renderedComponent = inst.render();
|
|
6827
|
+
if ("development" !== 'production') {
|
|
6828
|
+
if (this._debugID !== 0) {
|
|
6829
|
+
ReactInstrumentation.debugTool.onEndLifeCycleTimer(this._debugID, 'render');
|
|
6830
|
+
}
|
|
6831
|
+
}
|
|
6832
|
+
|
|
6485
6833
|
if ("development" !== 'production') {
|
|
6486
6834
|
// We allow auto-mocks to proceed as if they're returning null.
|
|
6487
6835
|
if (renderedComponent === undefined && inst.render._isMockFunction) {
|
|
@@ -6508,6 +6856,7 @@ var ReactCompositeComponentMixin = {
|
|
|
6508
6856
|
!(
|
|
6509
6857
|
// TODO: An `isValidNode` function would probably be more appropriate
|
|
6510
6858
|
renderedComponent === null || renderedComponent === false || ReactElement.isValidElement(renderedComponent)) ? "development" !== 'production' ? invariant(false, '%s.render(): A valid React element (or null) must be returned. You may have ' + 'returned undefined, an array or some other invalid object.', this.getName() || 'ReactCompositeComponent') : invariant(false) : void 0;
|
|
6859
|
+
|
|
6511
6860
|
return renderedComponent;
|
|
6512
6861
|
},
|
|
6513
6862
|
|
|
@@ -6576,12 +6925,6 @@ var ReactCompositeComponentMixin = {
|
|
|
6576
6925
|
|
|
6577
6926
|
};
|
|
6578
6927
|
|
|
6579
|
-
ReactPerf.measureMethods(ReactCompositeComponentMixin, 'ReactCompositeComponent', {
|
|
6580
|
-
mountComponent: 'mountComponent',
|
|
6581
|
-
updateComponent: 'updateComponent',
|
|
6582
|
-
_renderValidatedComponent: '_renderValidatedComponent'
|
|
6583
|
-
});
|
|
6584
|
-
|
|
6585
6928
|
var ReactCompositeComponent = {
|
|
6586
6929
|
|
|
6587
6930
|
Mixin: ReactCompositeComponentMixin
|
|
@@ -6589,7 +6932,7 @@ var ReactCompositeComponent = {
|
|
|
6589
6932
|
};
|
|
6590
6933
|
|
|
6591
6934
|
module.exports = ReactCompositeComponent;
|
|
6592
|
-
},{"103":103,"153":153,"166":166,"173":173,"183":183,"184":184,"36":36,"
|
|
6935
|
+
},{"103":103,"153":153,"166":166,"173":173,"183":183,"184":184,"36":36,"40":40,"65":65,"68":68,"75":75,"76":76,"85":85,"89":89,"90":90,"93":93}],40:[function(_dereq_,module,exports){
|
|
6593
6936
|
/**
|
|
6594
6937
|
* Copyright 2013-present, Facebook, Inc.
|
|
6595
6938
|
* All rights reserved.
|
|
@@ -6621,7 +6964,7 @@ var ReactCurrentOwner = {
|
|
|
6621
6964
|
};
|
|
6622
6965
|
|
|
6623
6966
|
module.exports = ReactCurrentOwner;
|
|
6624
|
-
},{}],
|
|
6967
|
+
},{}],41:[function(_dereq_,module,exports){
|
|
6625
6968
|
/**
|
|
6626
6969
|
* Copyright 2013-present, Facebook, Inc.
|
|
6627
6970
|
* All rights reserved.
|
|
@@ -6637,10 +6980,9 @@ module.exports = ReactCurrentOwner;
|
|
|
6637
6980
|
|
|
6638
6981
|
'use strict';
|
|
6639
6982
|
|
|
6640
|
-
var ReactDOMComponentTree = _dereq_(
|
|
6641
|
-
var ReactDefaultInjection = _dereq_(
|
|
6642
|
-
var ReactMount = _dereq_(
|
|
6643
|
-
var ReactPerf = _dereq_(88);
|
|
6983
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
6984
|
+
var ReactDefaultInjection = _dereq_(64);
|
|
6985
|
+
var ReactMount = _dereq_(80);
|
|
6644
6986
|
var ReactReconciler = _dereq_(93);
|
|
6645
6987
|
var ReactUpdates = _dereq_(104);
|
|
6646
6988
|
var ReactVersion = _dereq_(105);
|
|
@@ -6652,11 +6994,9 @@ var warning = _dereq_(183);
|
|
|
6652
6994
|
|
|
6653
6995
|
ReactDefaultInjection.inject();
|
|
6654
6996
|
|
|
6655
|
-
var render = ReactPerf.measure('React', 'render', ReactMount.render);
|
|
6656
|
-
|
|
6657
6997
|
var React = {
|
|
6658
6998
|
findDOMNode: findDOMNode,
|
|
6659
|
-
render: render,
|
|
6999
|
+
render: ReactMount.render,
|
|
6660
7000
|
unmountComponentAtNode: ReactMount.unmountComponentAtNode,
|
|
6661
7001
|
version: ReactVersion,
|
|
6662
7002
|
|
|
@@ -6726,7 +7066,7 @@ if ("development" !== 'production') {
|
|
|
6726
7066
|
}
|
|
6727
7067
|
|
|
6728
7068
|
module.exports = React;
|
|
6729
|
-
},{"104":104,"105":105,"132":132,"140":140,"149":149,"159":159,"183":183,"
|
|
7069
|
+
},{"104":104,"105":105,"132":132,"140":140,"149":149,"159":159,"183":183,"45":45,"64":64,"80":80,"93":93}],42:[function(_dereq_,module,exports){
|
|
6730
7070
|
/**
|
|
6731
7071
|
* Copyright 2013-present, Facebook, Inc.
|
|
6732
7072
|
* All rights reserved.
|
|
@@ -6751,7 +7091,7 @@ var ReactDOMButton = {
|
|
|
6751
7091
|
};
|
|
6752
7092
|
|
|
6753
7093
|
module.exports = ReactDOMButton;
|
|
6754
|
-
},{"14":14}],
|
|
7094
|
+
},{"14":14}],43:[function(_dereq_,module,exports){
|
|
6755
7095
|
/**
|
|
6756
7096
|
* Copyright 2013-present, Facebook, Inc.
|
|
6757
7097
|
* All rights reserved.
|
|
@@ -6780,16 +7120,18 @@ var EventPluginHub = _dereq_(17);
|
|
|
6780
7120
|
var EventPluginRegistry = _dereq_(18);
|
|
6781
7121
|
var ReactBrowserEventEmitter = _dereq_(28);
|
|
6782
7122
|
var ReactComponentBrowserEnvironment = _dereq_(35);
|
|
6783
|
-
var ReactDOMButton = _dereq_(
|
|
6784
|
-
var ReactDOMComponentFlags = _dereq_(
|
|
6785
|
-
var ReactDOMComponentTree = _dereq_(
|
|
6786
|
-
var ReactDOMInput = _dereq_(
|
|
6787
|
-
var ReactDOMOption = _dereq_(
|
|
6788
|
-
var ReactDOMSelect = _dereq_(
|
|
6789
|
-
var ReactDOMTextarea = _dereq_(
|
|
6790
|
-
var
|
|
6791
|
-
var
|
|
7123
|
+
var ReactDOMButton = _dereq_(42);
|
|
7124
|
+
var ReactDOMComponentFlags = _dereq_(44);
|
|
7125
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
7126
|
+
var ReactDOMInput = _dereq_(52);
|
|
7127
|
+
var ReactDOMOption = _dereq_(54);
|
|
7128
|
+
var ReactDOMSelect = _dereq_(55);
|
|
7129
|
+
var ReactDOMTextarea = _dereq_(59);
|
|
7130
|
+
var ReactInstrumentation = _dereq_(76);
|
|
7131
|
+
var ReactMultiChild = _dereq_(81);
|
|
7132
|
+
var ReactServerRenderingTransaction = _dereq_(97);
|
|
6792
7133
|
|
|
7134
|
+
var emptyFunction = _dereq_(165);
|
|
6793
7135
|
var escapeTextContentForBrowser = _dereq_(131);
|
|
6794
7136
|
var invariant = _dereq_(173);
|
|
6795
7137
|
var isEventSupported = _dereq_(145);
|
|
@@ -6908,6 +7250,9 @@ function assertValidProps(component, props) {
|
|
|
6908
7250
|
}
|
|
6909
7251
|
|
|
6910
7252
|
function enqueuePutListener(inst, registrationName, listener, transaction) {
|
|
7253
|
+
if (transaction instanceof ReactServerRenderingTransaction) {
|
|
7254
|
+
return;
|
|
7255
|
+
}
|
|
6911
7256
|
if ("development" !== 'production') {
|
|
6912
7257
|
// IE8 has no API for event capturing and the `onScroll` event doesn't
|
|
6913
7258
|
// bubble.
|
|
@@ -6916,10 +7261,6 @@ function enqueuePutListener(inst, registrationName, listener, transaction) {
|
|
|
6916
7261
|
var containerInfo = inst._nativeContainerInfo;
|
|
6917
7262
|
var isDocumentFragment = containerInfo._node && containerInfo._node.nodeType === DOC_FRAGMENT_TYPE;
|
|
6918
7263
|
var doc = isDocumentFragment ? containerInfo._node : containerInfo._ownerDocument;
|
|
6919
|
-
if (!doc) {
|
|
6920
|
-
// Server rendering.
|
|
6921
|
-
return;
|
|
6922
|
-
}
|
|
6923
7264
|
listenTo(registrationName, doc);
|
|
6924
7265
|
transaction.getReactMountReady().enqueue(putListener, {
|
|
6925
7266
|
inst: inst,
|
|
@@ -6938,6 +7279,19 @@ function optionPostMount() {
|
|
|
6938
7279
|
ReactDOMOption.postMountWrapper(inst);
|
|
6939
7280
|
}
|
|
6940
7281
|
|
|
7282
|
+
var setContentChildForInstrumentation = emptyFunction;
|
|
7283
|
+
if ("development" !== 'production') {
|
|
7284
|
+
setContentChildForInstrumentation = function (contentToUse) {
|
|
7285
|
+
var debugID = this._debugID;
|
|
7286
|
+
var contentDebugID = debugID + '#text';
|
|
7287
|
+
this._contentDebugID = contentDebugID;
|
|
7288
|
+
ReactInstrumentation.debugTool.onSetDisplayName(contentDebugID, '#text');
|
|
7289
|
+
ReactInstrumentation.debugTool.onSetText(contentDebugID, '' + contentToUse);
|
|
7290
|
+
ReactInstrumentation.debugTool.onMountComponent(contentDebugID);
|
|
7291
|
+
ReactInstrumentation.debugTool.onSetChildren(debugID, [contentDebugID]);
|
|
7292
|
+
};
|
|
7293
|
+
}
|
|
7294
|
+
|
|
6941
7295
|
// There are so many media events, it makes sense to just
|
|
6942
7296
|
// maintain a list rather than create a `trapBubbledEvent` for each
|
|
6943
7297
|
var mediaEvents = {
|
|
@@ -7098,6 +7452,7 @@ function ReactDOMComponent(element) {
|
|
|
7098
7452
|
this._flags = 0;
|
|
7099
7453
|
if ("development" !== 'production') {
|
|
7100
7454
|
this._ancestorInfo = null;
|
|
7455
|
+
this._contentDebugID = null;
|
|
7101
7456
|
}
|
|
7102
7457
|
}
|
|
7103
7458
|
|
|
@@ -7213,7 +7568,7 @@ ReactDOMComponent.Mixin = {
|
|
|
7213
7568
|
div.innerHTML = '<' + type + '></' + type + '>';
|
|
7214
7569
|
el = div.removeChild(div.firstChild);
|
|
7215
7570
|
} else {
|
|
7216
|
-
el = ownerDocument.createElement(this._currentElement.type);
|
|
7571
|
+
el = ownerDocument.createElement(this._currentElement.type, props.is || null);
|
|
7217
7572
|
}
|
|
7218
7573
|
} else {
|
|
7219
7574
|
el = ownerDocument.createElementNS(namespaceURI, this._currentElement.type);
|
|
@@ -7343,6 +7698,9 @@ ReactDOMComponent.Mixin = {
|
|
|
7343
7698
|
if (contentToUse != null) {
|
|
7344
7699
|
// TODO: Validate that text is allowed as a child of this node
|
|
7345
7700
|
ret = escapeTextContentForBrowser(contentToUse);
|
|
7701
|
+
if ("development" !== 'production') {
|
|
7702
|
+
setContentChildForInstrumentation.call(this, contentToUse);
|
|
7703
|
+
}
|
|
7346
7704
|
} else if (childrenToUse != null) {
|
|
7347
7705
|
var mountImages = this.mountChildren(childrenToUse, transaction, context);
|
|
7348
7706
|
ret = mountImages.join('');
|
|
@@ -7377,6 +7735,9 @@ ReactDOMComponent.Mixin = {
|
|
|
7377
7735
|
var childrenToUse = contentToUse != null ? null : props.children;
|
|
7378
7736
|
if (contentToUse != null) {
|
|
7379
7737
|
// TODO: Validate that text is allowed as a child of this node
|
|
7738
|
+
if ("development" !== 'production') {
|
|
7739
|
+
setContentChildForInstrumentation.call(this, contentToUse);
|
|
7740
|
+
}
|
|
7380
7741
|
DOMLazyTree.queueText(lazyTree, contentToUse);
|
|
7381
7742
|
} else if (childrenToUse != null) {
|
|
7382
7743
|
var mountImages = this.mountChildren(childrenToUse, transaction, context);
|
|
@@ -7585,17 +7946,34 @@ ReactDOMComponent.Mixin = {
|
|
|
7585
7946
|
this.updateChildren(null, transaction, context);
|
|
7586
7947
|
} else if (lastHasContentOrHtml && !nextHasContentOrHtml) {
|
|
7587
7948
|
this.updateTextContent('');
|
|
7949
|
+
if ("development" !== 'production') {
|
|
7950
|
+
ReactInstrumentation.debugTool.onSetChildren(this._debugID, []);
|
|
7951
|
+
}
|
|
7588
7952
|
}
|
|
7589
7953
|
|
|
7590
7954
|
if (nextContent != null) {
|
|
7591
7955
|
if (lastContent !== nextContent) {
|
|
7592
7956
|
this.updateTextContent('' + nextContent);
|
|
7957
|
+
if ("development" !== 'production') {
|
|
7958
|
+
this._contentDebugID = this._debugID + '#text';
|
|
7959
|
+
setContentChildForInstrumentation.call(this, nextContent);
|
|
7960
|
+
}
|
|
7593
7961
|
}
|
|
7594
7962
|
} else if (nextHtml != null) {
|
|
7595
7963
|
if (lastHtml !== nextHtml) {
|
|
7596
7964
|
this.updateMarkup('' + nextHtml);
|
|
7597
7965
|
}
|
|
7966
|
+
if ("development" !== 'production') {
|
|
7967
|
+
ReactInstrumentation.debugTool.onSetChildren(this._debugID, []);
|
|
7968
|
+
}
|
|
7598
7969
|
} else if (nextChildren != null) {
|
|
7970
|
+
if ("development" !== 'production') {
|
|
7971
|
+
if (this._contentDebugID) {
|
|
7972
|
+
ReactInstrumentation.debugTool.onUnmountComponent(this._contentDebugID);
|
|
7973
|
+
this._contentDebugID = null;
|
|
7974
|
+
}
|
|
7975
|
+
}
|
|
7976
|
+
|
|
7599
7977
|
this.updateChildren(nextChildren, transaction, context);
|
|
7600
7978
|
}
|
|
7601
7979
|
},
|
|
@@ -7645,6 +8023,13 @@ ReactDOMComponent.Mixin = {
|
|
|
7645
8023
|
this._rootNodeID = null;
|
|
7646
8024
|
this._domID = null;
|
|
7647
8025
|
this._wrapperState = null;
|
|
8026
|
+
|
|
8027
|
+
if ("development" !== 'production') {
|
|
8028
|
+
if (this._contentDebugID) {
|
|
8029
|
+
ReactInstrumentation.debugTool.onUnmountComponent(this._contentDebugID);
|
|
8030
|
+
this._contentDebugID = null;
|
|
8031
|
+
}
|
|
8032
|
+
}
|
|
7648
8033
|
},
|
|
7649
8034
|
|
|
7650
8035
|
getPublicInstance: function () {
|
|
@@ -7653,15 +8038,10 @@ ReactDOMComponent.Mixin = {
|
|
|
7653
8038
|
|
|
7654
8039
|
};
|
|
7655
8040
|
|
|
7656
|
-
ReactPerf.measureMethods(ReactDOMComponent.Mixin, 'ReactDOMComponent', {
|
|
7657
|
-
mountComponent: 'mountComponent',
|
|
7658
|
-
receiveComponent: 'receiveComponent'
|
|
7659
|
-
});
|
|
7660
|
-
|
|
7661
8041
|
_assign(ReactDOMComponent.prototype, ReactDOMComponent.Mixin, ReactMultiChild.Mixin);
|
|
7662
8042
|
|
|
7663
8043
|
module.exports = ReactDOMComponent;
|
|
7664
|
-
},{"1":1,"10":10,"11":11,"131":131,"145":145,"156":156,"16":16,"17":17,"173":173,"177":177,"18":18,"182":182,"183":183,"184":184,"28":28,"35":35,"4":4,"
|
|
8044
|
+
},{"1":1,"10":10,"11":11,"131":131,"145":145,"156":156,"16":16,"165":165,"17":17,"173":173,"177":177,"18":18,"182":182,"183":183,"184":184,"28":28,"35":35,"4":4,"42":42,"44":44,"45":45,"52":52,"54":54,"55":55,"59":59,"76":76,"8":8,"81":81,"9":9,"97":97}],44:[function(_dereq_,module,exports){
|
|
7665
8045
|
/**
|
|
7666
8046
|
* Copyright 2015-present, Facebook, Inc.
|
|
7667
8047
|
* All rights reserved.
|
|
@@ -7680,7 +8060,7 @@ var ReactDOMComponentFlags = {
|
|
|
7680
8060
|
};
|
|
7681
8061
|
|
|
7682
8062
|
module.exports = ReactDOMComponentFlags;
|
|
7683
|
-
},{}],
|
|
8063
|
+
},{}],45:[function(_dereq_,module,exports){
|
|
7684
8064
|
/**
|
|
7685
8065
|
* Copyright 2013-present, Facebook, Inc.
|
|
7686
8066
|
* All rights reserved.
|
|
@@ -7695,7 +8075,7 @@ module.exports = ReactDOMComponentFlags;
|
|
|
7695
8075
|
'use strict';
|
|
7696
8076
|
|
|
7697
8077
|
var DOMProperty = _dereq_(10);
|
|
7698
|
-
var ReactDOMComponentFlags = _dereq_(
|
|
8078
|
+
var ReactDOMComponentFlags = _dereq_(44);
|
|
7699
8079
|
|
|
7700
8080
|
var invariant = _dereq_(173);
|
|
7701
8081
|
|
|
@@ -7867,7 +8247,7 @@ var ReactDOMComponentTree = {
|
|
|
7867
8247
|
};
|
|
7868
8248
|
|
|
7869
8249
|
module.exports = ReactDOMComponentTree;
|
|
7870
|
-
},{"10":10,"173":173,"
|
|
8250
|
+
},{"10":10,"173":173,"44":44}],46:[function(_dereq_,module,exports){
|
|
7871
8251
|
/**
|
|
7872
8252
|
* Copyright 2013-present, Facebook, Inc.
|
|
7873
8253
|
* All rights reserved.
|
|
@@ -7901,7 +8281,7 @@ function ReactDOMContainerInfo(topLevelWrapper, node) {
|
|
|
7901
8281
|
}
|
|
7902
8282
|
|
|
7903
8283
|
module.exports = ReactDOMContainerInfo;
|
|
7904
|
-
},{"156":156}],
|
|
8284
|
+
},{"156":156}],47:[function(_dereq_,module,exports){
|
|
7905
8285
|
/**
|
|
7906
8286
|
* Copyright 2013-present, Facebook, Inc.
|
|
7907
8287
|
* All rights reserved.
|
|
@@ -7915,7 +8295,7 @@ module.exports = ReactDOMContainerInfo;
|
|
|
7915
8295
|
|
|
7916
8296
|
'use strict';
|
|
7917
8297
|
|
|
7918
|
-
var ReactDOMUnknownPropertyDevtool = _dereq_(
|
|
8298
|
+
var ReactDOMUnknownPropertyDevtool = _dereq_(61);
|
|
7919
8299
|
|
|
7920
8300
|
var warning = _dereq_(183);
|
|
7921
8301
|
|
|
@@ -7963,7 +8343,7 @@ var ReactDOMDebugTool = {
|
|
|
7963
8343
|
ReactDOMDebugTool.addDevtool(ReactDOMUnknownPropertyDevtool);
|
|
7964
8344
|
|
|
7965
8345
|
module.exports = ReactDOMDebugTool;
|
|
7966
|
-
},{"183":183,"
|
|
8346
|
+
},{"183":183,"61":61}],48:[function(_dereq_,module,exports){
|
|
7967
8347
|
/**
|
|
7968
8348
|
* Copyright 2014-present, Facebook, Inc.
|
|
7969
8349
|
* All rights reserved.
|
|
@@ -7980,7 +8360,7 @@ module.exports = ReactDOMDebugTool;
|
|
|
7980
8360
|
var _assign = _dereq_(184);
|
|
7981
8361
|
|
|
7982
8362
|
var DOMLazyTree = _dereq_(8);
|
|
7983
|
-
var ReactDOMComponentTree = _dereq_(
|
|
8363
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
7984
8364
|
|
|
7985
8365
|
var ReactDOMEmptyComponent = function (instantiate) {
|
|
7986
8366
|
// ReactCompositeComponent uses this:
|
|
@@ -8024,7 +8404,7 @@ _assign(ReactDOMEmptyComponent.prototype, {
|
|
|
8024
8404
|
});
|
|
8025
8405
|
|
|
8026
8406
|
module.exports = ReactDOMEmptyComponent;
|
|
8027
|
-
},{"184":184,"
|
|
8407
|
+
},{"184":184,"45":45,"8":8}],49:[function(_dereq_,module,exports){
|
|
8028
8408
|
/**
|
|
8029
8409
|
* Copyright 2013-present, Facebook, Inc.
|
|
8030
8410
|
* All rights reserved.
|
|
@@ -8038,8 +8418,8 @@ module.exports = ReactDOMEmptyComponent;
|
|
|
8038
8418
|
|
|
8039
8419
|
'use strict';
|
|
8040
8420
|
|
|
8041
|
-
var ReactElement = _dereq_(
|
|
8042
|
-
var ReactElementValidator = _dereq_(
|
|
8421
|
+
var ReactElement = _dereq_(65);
|
|
8422
|
+
var ReactElementValidator = _dereq_(66);
|
|
8043
8423
|
|
|
8044
8424
|
var mapObject = _dereq_(178);
|
|
8045
8425
|
|
|
@@ -8201,7 +8581,7 @@ var ReactDOMFactories = mapObject({
|
|
|
8201
8581
|
}, createDOMFactory);
|
|
8202
8582
|
|
|
8203
8583
|
module.exports = ReactDOMFactories;
|
|
8204
|
-
},{"178":178,"
|
|
8584
|
+
},{"178":178,"65":65,"66":66}],50:[function(_dereq_,module,exports){
|
|
8205
8585
|
/**
|
|
8206
8586
|
* Copyright 2013-present, Facebook, Inc.
|
|
8207
8587
|
* All rights reserved.
|
|
@@ -8220,7 +8600,7 @@ var ReactDOMFeatureFlags = {
|
|
|
8220
8600
|
};
|
|
8221
8601
|
|
|
8222
8602
|
module.exports = ReactDOMFeatureFlags;
|
|
8223
|
-
},{}],
|
|
8603
|
+
},{}],51:[function(_dereq_,module,exports){
|
|
8224
8604
|
/**
|
|
8225
8605
|
* Copyright 2013-present, Facebook, Inc.
|
|
8226
8606
|
* All rights reserved.
|
|
@@ -8235,8 +8615,7 @@ module.exports = ReactDOMFeatureFlags;
|
|
|
8235
8615
|
'use strict';
|
|
8236
8616
|
|
|
8237
8617
|
var DOMChildrenOperations = _dereq_(7);
|
|
8238
|
-
var ReactDOMComponentTree = _dereq_(
|
|
8239
|
-
var ReactPerf = _dereq_(88);
|
|
8618
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
8240
8619
|
|
|
8241
8620
|
/**
|
|
8242
8621
|
* Operations used to process updates to DOM nodes.
|
|
@@ -8255,12 +8634,8 @@ var ReactDOMIDOperations = {
|
|
|
8255
8634
|
}
|
|
8256
8635
|
};
|
|
8257
8636
|
|
|
8258
|
-
ReactPerf.measureMethods(ReactDOMIDOperations, 'ReactDOMIDOperations', {
|
|
8259
|
-
dangerouslyProcessChildrenUpdates: 'dangerouslyProcessChildrenUpdates'
|
|
8260
|
-
});
|
|
8261
|
-
|
|
8262
8637
|
module.exports = ReactDOMIDOperations;
|
|
8263
|
-
},{"
|
|
8638
|
+
},{"45":45,"7":7}],52:[function(_dereq_,module,exports){
|
|
8264
8639
|
/**
|
|
8265
8640
|
* Copyright 2013-present, Facebook, Inc.
|
|
8266
8641
|
* All rights reserved.
|
|
@@ -8279,7 +8654,7 @@ var _assign = _dereq_(184);
|
|
|
8279
8654
|
var DisabledInputUtils = _dereq_(14);
|
|
8280
8655
|
var DOMPropertyOperations = _dereq_(11);
|
|
8281
8656
|
var LinkedValueUtils = _dereq_(25);
|
|
8282
|
-
var ReactDOMComponentTree = _dereq_(
|
|
8657
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
8283
8658
|
var ReactUpdates = _dereq_(104);
|
|
8284
8659
|
|
|
8285
8660
|
var invariant = _dereq_(173);
|
|
@@ -8348,6 +8723,8 @@ var ReactDOMInput = {
|
|
|
8348
8723
|
if ("development" !== 'production') {
|
|
8349
8724
|
LinkedValueUtils.checkPropTypes('input', props, inst._currentElement._owner);
|
|
8350
8725
|
|
|
8726
|
+
var owner = inst._currentElement._owner;
|
|
8727
|
+
|
|
8351
8728
|
if (props.valueLink !== undefined && !didWarnValueLink) {
|
|
8352
8729
|
"development" !== 'production' ? warning(false, '`valueLink` prop on `input` is deprecated; set `value` and `onChange` instead.') : void 0;
|
|
8353
8730
|
didWarnValueLink = true;
|
|
@@ -8357,11 +8734,11 @@ var ReactDOMInput = {
|
|
|
8357
8734
|
didWarnCheckedLink = true;
|
|
8358
8735
|
}
|
|
8359
8736
|
if (props.checked !== undefined && props.defaultChecked !== undefined && !didWarnCheckedDefaultChecked) {
|
|
8360
|
-
"development" !== 'production' ? warning(false, 'Input elements must be either controlled or uncontrolled ' + '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0;
|
|
8737
|
+
"development" !== 'production' ? warning(false, '%s contains an input of type %s with both checked and defaultChecked props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0;
|
|
8361
8738
|
didWarnCheckedDefaultChecked = true;
|
|
8362
8739
|
}
|
|
8363
8740
|
if (props.value !== undefined && props.defaultValue !== undefined && !didWarnValueDefaultValue) {
|
|
8364
|
-
"development" !== 'production' ? warning(false, 'Input elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components') : void 0;
|
|
8741
|
+
"development" !== 'production' ? warning(false, '%s contains an input of type %s with both value and defaultValue props. ' + 'Input elements must be either controlled or uncontrolled ' + '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + 'https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0;
|
|
8365
8742
|
didWarnValueDefaultValue = true;
|
|
8366
8743
|
}
|
|
8367
8744
|
warnIfValueIsNull(props);
|
|
@@ -8392,7 +8769,7 @@ var ReactDOMInput = {
|
|
|
8392
8769
|
var owner = inst._currentElement._owner;
|
|
8393
8770
|
|
|
8394
8771
|
if ((initialValue || !inst._wrapperState.controlled) && controlled && !didWarnUncontrolledToControlled) {
|
|
8395
|
-
"development" !== 'production' ? warning(false, '%s is changing
|
|
8772
|
+
"development" !== 'production' ? warning(false, '%s is changing an uncontrolled input of type %s to be controlled. ' + 'Input elements should not switch from uncontrolled to controlled (or vice versa). ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', owner && owner.getName() || 'A component', props.type) : void 0;
|
|
8396
8773
|
didWarnUncontrolledToControlled = true;
|
|
8397
8774
|
}
|
|
8398
8775
|
if (inst._wrapperState.controlled && (defaultValue || !controlled) && !didWarnControlledToUncontrolled) {
|
|
@@ -8465,7 +8842,7 @@ function _handleChange(event) {
|
|
|
8465
8842
|
}
|
|
8466
8843
|
|
|
8467
8844
|
module.exports = ReactDOMInput;
|
|
8468
|
-
},{"104":104,"11":11,"14":14,"173":173,"183":183,"184":184,"25":25,"
|
|
8845
|
+
},{"104":104,"11":11,"14":14,"173":173,"183":183,"184":184,"25":25,"45":45}],53:[function(_dereq_,module,exports){
|
|
8469
8846
|
/**
|
|
8470
8847
|
* Copyright 2013-present, Facebook, Inc.
|
|
8471
8848
|
* All rights reserved.
|
|
@@ -8479,10 +8856,10 @@ module.exports = ReactDOMInput;
|
|
|
8479
8856
|
|
|
8480
8857
|
'use strict';
|
|
8481
8858
|
|
|
8482
|
-
var ReactDOMDebugTool = _dereq_(
|
|
8859
|
+
var ReactDOMDebugTool = _dereq_(47);
|
|
8483
8860
|
|
|
8484
8861
|
module.exports = { debugTool: ReactDOMDebugTool };
|
|
8485
|
-
},{"
|
|
8862
|
+
},{"47":47}],54:[function(_dereq_,module,exports){
|
|
8486
8863
|
/**
|
|
8487
8864
|
* Copyright 2013-present, Facebook, Inc.
|
|
8488
8865
|
* All rights reserved.
|
|
@@ -8499,8 +8876,8 @@ module.exports = { debugTool: ReactDOMDebugTool };
|
|
|
8499
8876
|
var _assign = _dereq_(184);
|
|
8500
8877
|
|
|
8501
8878
|
var ReactChildren = _dereq_(32);
|
|
8502
|
-
var ReactDOMComponentTree = _dereq_(
|
|
8503
|
-
var ReactDOMSelect = _dereq_(
|
|
8879
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
8880
|
+
var ReactDOMSelect = _dereq_(55);
|
|
8504
8881
|
|
|
8505
8882
|
var warning = _dereq_(183);
|
|
8506
8883
|
|
|
@@ -8592,7 +8969,7 @@ var ReactDOMOption = {
|
|
|
8592
8969
|
};
|
|
8593
8970
|
|
|
8594
8971
|
module.exports = ReactDOMOption;
|
|
8595
|
-
},{"183":183,"184":184,"32":32,"
|
|
8972
|
+
},{"183":183,"184":184,"32":32,"45":45,"55":55}],55:[function(_dereq_,module,exports){
|
|
8596
8973
|
/**
|
|
8597
8974
|
* Copyright 2013-present, Facebook, Inc.
|
|
8598
8975
|
* All rights reserved.
|
|
@@ -8610,7 +8987,7 @@ var _assign = _dereq_(184);
|
|
|
8610
8987
|
|
|
8611
8988
|
var DisabledInputUtils = _dereq_(14);
|
|
8612
8989
|
var LinkedValueUtils = _dereq_(25);
|
|
8613
|
-
var ReactDOMComponentTree = _dereq_(
|
|
8990
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
8614
8991
|
var ReactUpdates = _dereq_(104);
|
|
8615
8992
|
|
|
8616
8993
|
var warning = _dereq_(183);
|
|
@@ -8806,7 +9183,7 @@ function _handleChange(event) {
|
|
|
8806
9183
|
}
|
|
8807
9184
|
|
|
8808
9185
|
module.exports = ReactDOMSelect;
|
|
8809
|
-
},{"104":104,"14":14,"183":183,"184":184,"25":25,"
|
|
9186
|
+
},{"104":104,"14":14,"183":183,"184":184,"25":25,"45":45}],56:[function(_dereq_,module,exports){
|
|
8810
9187
|
/**
|
|
8811
9188
|
* Copyright 2013-present, Facebook, Inc.
|
|
8812
9189
|
* All rights reserved.
|
|
@@ -9019,7 +9396,7 @@ var ReactDOMSelection = {
|
|
|
9019
9396
|
};
|
|
9020
9397
|
|
|
9021
9398
|
module.exports = ReactDOMSelection;
|
|
9022
|
-
},{"141":141,"142":142,"159":159}],
|
|
9399
|
+
},{"141":141,"142":142,"159":159}],57:[function(_dereq_,module,exports){
|
|
9023
9400
|
/**
|
|
9024
9401
|
* Copyright 2013-present, Facebook, Inc.
|
|
9025
9402
|
* All rights reserved.
|
|
@@ -9033,7 +9410,7 @@ module.exports = ReactDOMSelection;
|
|
|
9033
9410
|
|
|
9034
9411
|
'use strict';
|
|
9035
9412
|
|
|
9036
|
-
var ReactDefaultInjection = _dereq_(
|
|
9413
|
+
var ReactDefaultInjection = _dereq_(64);
|
|
9037
9414
|
var ReactServerRendering = _dereq_(96);
|
|
9038
9415
|
var ReactVersion = _dereq_(105);
|
|
9039
9416
|
|
|
@@ -9046,7 +9423,7 @@ var ReactDOMServer = {
|
|
|
9046
9423
|
};
|
|
9047
9424
|
|
|
9048
9425
|
module.exports = ReactDOMServer;
|
|
9049
|
-
},{"105":105,"
|
|
9426
|
+
},{"105":105,"64":64,"96":96}],58:[function(_dereq_,module,exports){
|
|
9050
9427
|
/**
|
|
9051
9428
|
* Copyright 2013-present, Facebook, Inc.
|
|
9052
9429
|
* All rights reserved.
|
|
@@ -9064,8 +9441,8 @@ var _assign = _dereq_(184);
|
|
|
9064
9441
|
|
|
9065
9442
|
var DOMChildrenOperations = _dereq_(7);
|
|
9066
9443
|
var DOMLazyTree = _dereq_(8);
|
|
9067
|
-
var ReactDOMComponentTree = _dereq_(
|
|
9068
|
-
var
|
|
9444
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
9445
|
+
var ReactInstrumentation = _dereq_(76);
|
|
9069
9446
|
|
|
9070
9447
|
var escapeTextContentForBrowser = _dereq_(131);
|
|
9071
9448
|
var invariant = _dereq_(173);
|
|
@@ -9113,6 +9490,8 @@ _assign(ReactDOMTextComponent.prototype, {
|
|
|
9113
9490
|
*/
|
|
9114
9491
|
mountComponent: function (transaction, nativeParent, nativeContainerInfo, context) {
|
|
9115
9492
|
if ("development" !== 'production') {
|
|
9493
|
+
ReactInstrumentation.debugTool.onSetText(this._debugID, this._stringText);
|
|
9494
|
+
|
|
9116
9495
|
var parentInfo;
|
|
9117
9496
|
if (nativeParent != null) {
|
|
9118
9497
|
parentInfo = nativeParent._ancestorInfo;
|
|
@@ -9176,6 +9555,10 @@ _assign(ReactDOMTextComponent.prototype, {
|
|
|
9176
9555
|
this._stringText = nextStringText;
|
|
9177
9556
|
var commentNodes = this.getNativeNode();
|
|
9178
9557
|
DOMChildrenOperations.replaceDelimitedText(commentNodes[0], commentNodes[1], nextStringText);
|
|
9558
|
+
|
|
9559
|
+
if ("development" !== 'production') {
|
|
9560
|
+
ReactInstrumentation.debugTool.onSetText(this._debugID, nextStringText);
|
|
9561
|
+
}
|
|
9179
9562
|
}
|
|
9180
9563
|
}
|
|
9181
9564
|
},
|
|
@@ -9210,13 +9593,8 @@ _assign(ReactDOMTextComponent.prototype, {
|
|
|
9210
9593
|
|
|
9211
9594
|
});
|
|
9212
9595
|
|
|
9213
|
-
ReactPerf.measureMethods(ReactDOMTextComponent.prototype, 'ReactDOMTextComponent', {
|
|
9214
|
-
mountComponent: 'mountComponent',
|
|
9215
|
-
receiveComponent: 'receiveComponent'
|
|
9216
|
-
});
|
|
9217
|
-
|
|
9218
9596
|
module.exports = ReactDOMTextComponent;
|
|
9219
|
-
},{"131":131,"156":156,"173":173,"184":184,"
|
|
9597
|
+
},{"131":131,"156":156,"173":173,"184":184,"45":45,"7":7,"76":76,"8":8}],59:[function(_dereq_,module,exports){
|
|
9220
9598
|
/**
|
|
9221
9599
|
* Copyright 2013-present, Facebook, Inc.
|
|
9222
9600
|
* All rights reserved.
|
|
@@ -9235,7 +9613,7 @@ var _assign = _dereq_(184);
|
|
|
9235
9613
|
var DisabledInputUtils = _dereq_(14);
|
|
9236
9614
|
var DOMPropertyOperations = _dereq_(11);
|
|
9237
9615
|
var LinkedValueUtils = _dereq_(25);
|
|
9238
|
-
var ReactDOMComponentTree = _dereq_(
|
|
9616
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
9239
9617
|
var ReactUpdates = _dereq_(104);
|
|
9240
9618
|
|
|
9241
9619
|
var invariant = _dereq_(173);
|
|
@@ -9359,7 +9737,7 @@ function _handleChange(event) {
|
|
|
9359
9737
|
}
|
|
9360
9738
|
|
|
9361
9739
|
module.exports = ReactDOMTextarea;
|
|
9362
|
-
},{"104":104,"11":11,"14":14,"173":173,"183":183,"184":184,"25":25,"
|
|
9740
|
+
},{"104":104,"11":11,"14":14,"173":173,"183":183,"184":184,"25":25,"45":45}],60:[function(_dereq_,module,exports){
|
|
9363
9741
|
/**
|
|
9364
9742
|
* Copyright 2015-present, Facebook, Inc.
|
|
9365
9743
|
* All rights reserved.
|
|
@@ -9494,7 +9872,7 @@ module.exports = {
|
|
|
9494
9872
|
traverseTwoPhase: traverseTwoPhase,
|
|
9495
9873
|
traverseEnterLeave: traverseEnterLeave
|
|
9496
9874
|
};
|
|
9497
|
-
},{"173":173}],
|
|
9875
|
+
},{"173":173}],61:[function(_dereq_,module,exports){
|
|
9498
9876
|
/**
|
|
9499
9877
|
* Copyright 2013-present, Facebook, Inc.
|
|
9500
9878
|
* All rights reserved.
|
|
@@ -9559,7 +9937,7 @@ var ReactDOMUnknownPropertyDevtool = {
|
|
|
9559
9937
|
};
|
|
9560
9938
|
|
|
9561
9939
|
module.exports = ReactDOMUnknownPropertyDevtool;
|
|
9562
|
-
},{"10":10,"18":18,"183":183}],
|
|
9940
|
+
},{"10":10,"18":18,"183":183}],62:[function(_dereq_,module,exports){
|
|
9563
9941
|
/**
|
|
9564
9942
|
* Copyright 2016-present, Facebook, Inc.
|
|
9565
9943
|
* All rights reserved.
|
|
@@ -9573,7 +9951,9 @@ module.exports = ReactDOMUnknownPropertyDevtool;
|
|
|
9573
9951
|
|
|
9574
9952
|
'use strict';
|
|
9575
9953
|
|
|
9576
|
-
var
|
|
9954
|
+
var ExecutionEnvironment = _dereq_(159);
|
|
9955
|
+
|
|
9956
|
+
var performanceNow = _dereq_(181);
|
|
9577
9957
|
var warning = _dereq_(183);
|
|
9578
9958
|
|
|
9579
9959
|
var eventHandlers = [];
|
|
@@ -9594,6 +9974,70 @@ function emitEvent(handlerFunctionName, arg1, arg2, arg3, arg4, arg5) {
|
|
|
9594
9974
|
}
|
|
9595
9975
|
}
|
|
9596
9976
|
|
|
9977
|
+
var isProfiling = false;
|
|
9978
|
+
var flushHistory = [];
|
|
9979
|
+
var currentFlushNesting = 0;
|
|
9980
|
+
var currentFlushMeasurements = null;
|
|
9981
|
+
var currentFlushStartTime = null;
|
|
9982
|
+
var currentTimerDebugID = null;
|
|
9983
|
+
var currentTimerStartTime = null;
|
|
9984
|
+
var currentTimerType = null;
|
|
9985
|
+
|
|
9986
|
+
function clearHistory() {
|
|
9987
|
+
ReactComponentTreeDevtool.purgeUnmountedComponents();
|
|
9988
|
+
ReactNativeOperationHistoryDevtool.clearHistory();
|
|
9989
|
+
}
|
|
9990
|
+
|
|
9991
|
+
function getTreeSnapshot(registeredIDs) {
|
|
9992
|
+
return registeredIDs.reduce(function (tree, id) {
|
|
9993
|
+
var ownerID = ReactComponentTreeDevtool.getOwnerID(id);
|
|
9994
|
+
var parentID = ReactComponentTreeDevtool.getParentID(id);
|
|
9995
|
+
tree[id] = {
|
|
9996
|
+
displayName: ReactComponentTreeDevtool.getDisplayName(id),
|
|
9997
|
+
text: ReactComponentTreeDevtool.getText(id),
|
|
9998
|
+
updateCount: ReactComponentTreeDevtool.getUpdateCount(id),
|
|
9999
|
+
childIDs: ReactComponentTreeDevtool.getChildIDs(id),
|
|
10000
|
+
// Text nodes don't have owners but this is close enough.
|
|
10001
|
+
ownerID: ownerID || ReactComponentTreeDevtool.getOwnerID(parentID),
|
|
10002
|
+
parentID: parentID
|
|
10003
|
+
};
|
|
10004
|
+
return tree;
|
|
10005
|
+
}, {});
|
|
10006
|
+
}
|
|
10007
|
+
|
|
10008
|
+
function resetMeasurements() {
|
|
10009
|
+
if ("development" !== 'production') {
|
|
10010
|
+
var previousStartTime = currentFlushStartTime;
|
|
10011
|
+
var previousMeasurements = currentFlushMeasurements || [];
|
|
10012
|
+
var previousOperations = ReactNativeOperationHistoryDevtool.getHistory();
|
|
10013
|
+
|
|
10014
|
+
if (!isProfiling || currentFlushNesting === 0) {
|
|
10015
|
+
currentFlushStartTime = null;
|
|
10016
|
+
currentFlushMeasurements = null;
|
|
10017
|
+
clearHistory();
|
|
10018
|
+
return;
|
|
10019
|
+
}
|
|
10020
|
+
|
|
10021
|
+
if (previousMeasurements.length || previousOperations.length) {
|
|
10022
|
+
var registeredIDs = ReactComponentTreeDevtool.getRegisteredIDs();
|
|
10023
|
+
flushHistory.push({
|
|
10024
|
+
duration: performanceNow() - previousStartTime,
|
|
10025
|
+
measurements: previousMeasurements || [],
|
|
10026
|
+
operations: previousOperations || [],
|
|
10027
|
+
treeSnapshot: getTreeSnapshot(registeredIDs)
|
|
10028
|
+
});
|
|
10029
|
+
}
|
|
10030
|
+
|
|
10031
|
+
clearHistory();
|
|
10032
|
+
currentFlushStartTime = performanceNow();
|
|
10033
|
+
currentFlushMeasurements = [];
|
|
10034
|
+
}
|
|
10035
|
+
}
|
|
10036
|
+
|
|
10037
|
+
function checkDebugID(debugID) {
|
|
10038
|
+
"development" !== 'production' ? warning(debugID, 'ReactDebugTool: debugID may not be empty.') : void 0;
|
|
10039
|
+
}
|
|
10040
|
+
|
|
9597
10041
|
var ReactDebugTool = {
|
|
9598
10042
|
addDevtool: function (devtool) {
|
|
9599
10043
|
eventHandlers.push(devtool);
|
|
@@ -9606,33 +10050,145 @@ var ReactDebugTool = {
|
|
|
9606
10050
|
}
|
|
9607
10051
|
}
|
|
9608
10052
|
},
|
|
10053
|
+
beginProfiling: function () {
|
|
10054
|
+
if ("development" !== 'production') {
|
|
10055
|
+
if (isProfiling) {
|
|
10056
|
+
return;
|
|
10057
|
+
}
|
|
10058
|
+
|
|
10059
|
+
isProfiling = true;
|
|
10060
|
+
flushHistory.length = 0;
|
|
10061
|
+
resetMeasurements();
|
|
10062
|
+
}
|
|
10063
|
+
},
|
|
10064
|
+
endProfiling: function () {
|
|
10065
|
+
if ("development" !== 'production') {
|
|
10066
|
+
if (!isProfiling) {
|
|
10067
|
+
return;
|
|
10068
|
+
}
|
|
10069
|
+
|
|
10070
|
+
isProfiling = false;
|
|
10071
|
+
resetMeasurements();
|
|
10072
|
+
}
|
|
10073
|
+
},
|
|
10074
|
+
getFlushHistory: function () {
|
|
10075
|
+
if ("development" !== 'production') {
|
|
10076
|
+
return flushHistory;
|
|
10077
|
+
}
|
|
10078
|
+
},
|
|
10079
|
+
onBeginFlush: function () {
|
|
10080
|
+
if ("development" !== 'production') {
|
|
10081
|
+
currentFlushNesting++;
|
|
10082
|
+
resetMeasurements();
|
|
10083
|
+
}
|
|
10084
|
+
emitEvent('onBeginFlush');
|
|
10085
|
+
},
|
|
10086
|
+
onEndFlush: function () {
|
|
10087
|
+
if ("development" !== 'production') {
|
|
10088
|
+
resetMeasurements();
|
|
10089
|
+
currentFlushNesting--;
|
|
10090
|
+
}
|
|
10091
|
+
emitEvent('onEndFlush');
|
|
10092
|
+
},
|
|
10093
|
+
onBeginLifeCycleTimer: function (debugID, timerType) {
|
|
10094
|
+
checkDebugID(debugID);
|
|
10095
|
+
emitEvent('onBeginLifeCycleTimer', debugID, timerType);
|
|
10096
|
+
if ("development" !== 'production') {
|
|
10097
|
+
if (isProfiling && currentFlushNesting > 0) {
|
|
10098
|
+
"development" !== 'production' ? warning(!currentTimerType, 'There is an internal error in the React performance measurement code. ' + 'Did not expect %s timer to start while %s timer is still in ' + 'progress for %s instance.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0;
|
|
10099
|
+
currentTimerStartTime = performanceNow();
|
|
10100
|
+
currentTimerDebugID = debugID;
|
|
10101
|
+
currentTimerType = timerType;
|
|
10102
|
+
}
|
|
10103
|
+
}
|
|
10104
|
+
},
|
|
10105
|
+
onEndLifeCycleTimer: function (debugID, timerType) {
|
|
10106
|
+
checkDebugID(debugID);
|
|
10107
|
+
if ("development" !== 'production') {
|
|
10108
|
+
if (isProfiling && currentFlushNesting > 0) {
|
|
10109
|
+
"development" !== 'production' ? warning(currentTimerType === timerType, 'There is an internal error in the React performance measurement code. ' + 'We did not expect %s timer to stop while %s timer is still in ' + 'progress for %s instance. Please report this as a bug in React.', timerType, currentTimerType || 'no', debugID === currentTimerDebugID ? 'the same' : 'another') : void 0;
|
|
10110
|
+
currentFlushMeasurements.push({
|
|
10111
|
+
timerType: timerType,
|
|
10112
|
+
instanceID: debugID,
|
|
10113
|
+
duration: performanceNow() - currentTimerStartTime
|
|
10114
|
+
});
|
|
10115
|
+
currentTimerStartTime = null;
|
|
10116
|
+
currentTimerDebugID = null;
|
|
10117
|
+
currentTimerType = null;
|
|
10118
|
+
}
|
|
10119
|
+
}
|
|
10120
|
+
emitEvent('onEndLifeCycleTimer', debugID, timerType);
|
|
10121
|
+
},
|
|
10122
|
+
onBeginReconcilerTimer: function (debugID, timerType) {
|
|
10123
|
+
checkDebugID(debugID);
|
|
10124
|
+
emitEvent('onBeginReconcilerTimer', debugID, timerType);
|
|
10125
|
+
},
|
|
10126
|
+
onEndReconcilerTimer: function (debugID, timerType) {
|
|
10127
|
+
checkDebugID(debugID);
|
|
10128
|
+
emitEvent('onEndReconcilerTimer', debugID, timerType);
|
|
10129
|
+
},
|
|
9609
10130
|
onBeginProcessingChildContext: function () {
|
|
9610
10131
|
emitEvent('onBeginProcessingChildContext');
|
|
9611
10132
|
},
|
|
9612
10133
|
onEndProcessingChildContext: function () {
|
|
9613
10134
|
emitEvent('onEndProcessingChildContext');
|
|
9614
10135
|
},
|
|
10136
|
+
onNativeOperation: function (debugID, type, payload) {
|
|
10137
|
+
checkDebugID(debugID);
|
|
10138
|
+
emitEvent('onNativeOperation', debugID, type, payload);
|
|
10139
|
+
},
|
|
9615
10140
|
onSetState: function () {
|
|
9616
10141
|
emitEvent('onSetState');
|
|
9617
10142
|
},
|
|
9618
|
-
|
|
9619
|
-
|
|
10143
|
+
onSetDisplayName: function (debugID, displayName) {
|
|
10144
|
+
checkDebugID(debugID);
|
|
10145
|
+
emitEvent('onSetDisplayName', debugID, displayName);
|
|
10146
|
+
},
|
|
10147
|
+
onSetChildren: function (debugID, childDebugIDs) {
|
|
10148
|
+
checkDebugID(debugID);
|
|
10149
|
+
emitEvent('onSetChildren', debugID, childDebugIDs);
|
|
10150
|
+
},
|
|
10151
|
+
onSetOwner: function (debugID, ownerDebugID) {
|
|
10152
|
+
checkDebugID(debugID);
|
|
10153
|
+
emitEvent('onSetOwner', debugID, ownerDebugID);
|
|
10154
|
+
},
|
|
10155
|
+
onSetText: function (debugID, text) {
|
|
10156
|
+
checkDebugID(debugID);
|
|
10157
|
+
emitEvent('onSetText', debugID, text);
|
|
9620
10158
|
},
|
|
9621
|
-
|
|
9622
|
-
|
|
10159
|
+
onMountRootComponent: function (debugID) {
|
|
10160
|
+
checkDebugID(debugID);
|
|
10161
|
+
emitEvent('onMountRootComponent', debugID);
|
|
9623
10162
|
},
|
|
9624
|
-
|
|
9625
|
-
|
|
10163
|
+
onMountComponent: function (debugID) {
|
|
10164
|
+
checkDebugID(debugID);
|
|
10165
|
+
emitEvent('onMountComponent', debugID);
|
|
9626
10166
|
},
|
|
9627
|
-
|
|
9628
|
-
|
|
10167
|
+
onUpdateComponent: function (debugID) {
|
|
10168
|
+
checkDebugID(debugID);
|
|
10169
|
+
emitEvent('onUpdateComponent', debugID);
|
|
10170
|
+
},
|
|
10171
|
+
onUnmountComponent: function (debugID) {
|
|
10172
|
+
checkDebugID(debugID);
|
|
10173
|
+
emitEvent('onUnmountComponent', debugID);
|
|
9629
10174
|
}
|
|
9630
10175
|
};
|
|
9631
10176
|
|
|
9632
|
-
|
|
10177
|
+
if ("development" !== 'production') {
|
|
10178
|
+
var ReactInvalidSetStateWarningDevTool = _dereq_(77);
|
|
10179
|
+
var ReactNativeOperationHistoryDevtool = _dereq_(84);
|
|
10180
|
+
var ReactComponentTreeDevtool = _dereq_(37);
|
|
10181
|
+
ReactDebugTool.addDevtool(ReactInvalidSetStateWarningDevTool);
|
|
10182
|
+
ReactDebugTool.addDevtool(ReactComponentTreeDevtool);
|
|
10183
|
+
ReactDebugTool.addDevtool(ReactNativeOperationHistoryDevtool);
|
|
10184
|
+
var url = ExecutionEnvironment.canUseDOM && window.location.href || '';
|
|
10185
|
+
if (/[?&]react_perf\b/.test(url)) {
|
|
10186
|
+
ReactDebugTool.beginProfiling();
|
|
10187
|
+
}
|
|
10188
|
+
}
|
|
9633
10189
|
|
|
9634
10190
|
module.exports = ReactDebugTool;
|
|
9635
|
-
},{"183":183,"
|
|
10191
|
+
},{"159":159,"181":181,"183":183,"37":37,"77":77,"84":84}],63:[function(_dereq_,module,exports){
|
|
9636
10192
|
/**
|
|
9637
10193
|
* Copyright 2013-present, Facebook, Inc.
|
|
9638
10194
|
* All rights reserved.
|
|
@@ -9701,7 +10257,7 @@ var ReactDefaultBatchingStrategy = {
|
|
|
9701
10257
|
};
|
|
9702
10258
|
|
|
9703
10259
|
module.exports = ReactDefaultBatchingStrategy;
|
|
9704
|
-
},{"104":104,"124":124,"165":165,"184":184}],
|
|
10260
|
+
},{"104":104,"124":124,"165":165,"184":184}],64:[function(_dereq_,module,exports){
|
|
9705
10261
|
/**
|
|
9706
10262
|
* Copyright 2013-present, Facebook, Inc.
|
|
9707
10263
|
* All rights reserved.
|
|
@@ -9719,17 +10275,16 @@ var BeforeInputEventPlugin = _dereq_(2);
|
|
|
9719
10275
|
var ChangeEventPlugin = _dereq_(6);
|
|
9720
10276
|
var DefaultEventPluginOrder = _dereq_(13);
|
|
9721
10277
|
var EnterLeaveEventPlugin = _dereq_(15);
|
|
9722
|
-
var ExecutionEnvironment = _dereq_(159);
|
|
9723
10278
|
var HTMLDOMPropertyConfig = _dereq_(22);
|
|
9724
10279
|
var ReactComponentBrowserEnvironment = _dereq_(35);
|
|
9725
|
-
var ReactDOMComponent = _dereq_(
|
|
9726
|
-
var ReactDOMComponentTree = _dereq_(
|
|
9727
|
-
var ReactDOMEmptyComponent = _dereq_(
|
|
9728
|
-
var ReactDOMTreeTraversal = _dereq_(
|
|
9729
|
-
var ReactDOMTextComponent = _dereq_(
|
|
9730
|
-
var ReactDefaultBatchingStrategy = _dereq_(
|
|
9731
|
-
var ReactEventListener = _dereq_(
|
|
9732
|
-
var ReactInjection = _dereq_(
|
|
10280
|
+
var ReactDOMComponent = _dereq_(43);
|
|
10281
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
10282
|
+
var ReactDOMEmptyComponent = _dereq_(48);
|
|
10283
|
+
var ReactDOMTreeTraversal = _dereq_(60);
|
|
10284
|
+
var ReactDOMTextComponent = _dereq_(58);
|
|
10285
|
+
var ReactDefaultBatchingStrategy = _dereq_(63);
|
|
10286
|
+
var ReactEventListener = _dereq_(70);
|
|
10287
|
+
var ReactInjection = _dereq_(73);
|
|
9733
10288
|
var ReactReconcileTransaction = _dereq_(92);
|
|
9734
10289
|
var SVGDOMPropertyConfig = _dereq_(108);
|
|
9735
10290
|
var SelectEventPlugin = _dereq_(109);
|
|
@@ -9782,548 +10337,12 @@ function inject() {
|
|
|
9782
10337
|
ReactInjection.Updates.injectBatchingStrategy(ReactDefaultBatchingStrategy);
|
|
9783
10338
|
|
|
9784
10339
|
ReactInjection.Component.injectEnvironment(ReactComponentBrowserEnvironment);
|
|
9785
|
-
|
|
9786
|
-
if ("development" !== 'production') {
|
|
9787
|
-
var url = ExecutionEnvironment.canUseDOM && window.location.href || '';
|
|
9788
|
-
if (/[?&]react_perf\b/.test(url)) {
|
|
9789
|
-
var ReactDefaultPerf = _dereq_(64);
|
|
9790
|
-
ReactDefaultPerf.start();
|
|
9791
|
-
}
|
|
9792
|
-
}
|
|
9793
10340
|
}
|
|
9794
10341
|
|
|
9795
10342
|
module.exports = {
|
|
9796
10343
|
inject: inject
|
|
9797
10344
|
};
|
|
9798
|
-
},{"108":108,"109":109,"110":110,"13":13,"15":15,"
|
|
9799
|
-
/**
|
|
9800
|
-
* Copyright 2013-present, Facebook, Inc.
|
|
9801
|
-
* All rights reserved.
|
|
9802
|
-
*
|
|
9803
|
-
* This source code is licensed under the BSD-style license found in the
|
|
9804
|
-
* LICENSE file in the root directory of this source tree. An additional grant
|
|
9805
|
-
* of patent rights can be found in the PATENTS file in the same directory.
|
|
9806
|
-
*
|
|
9807
|
-
* @providesModule ReactDefaultPerf
|
|
9808
|
-
*/
|
|
9809
|
-
|
|
9810
|
-
'use strict';
|
|
9811
|
-
|
|
9812
|
-
var DOMProperty = _dereq_(10);
|
|
9813
|
-
var ReactDOMComponentTree = _dereq_(44);
|
|
9814
|
-
var ReactDefaultPerfAnalysis = _dereq_(65);
|
|
9815
|
-
var ReactMount = _dereq_(81);
|
|
9816
|
-
var ReactPerf = _dereq_(88);
|
|
9817
|
-
|
|
9818
|
-
var performanceNow = _dereq_(181);
|
|
9819
|
-
var warning = _dereq_(183);
|
|
9820
|
-
|
|
9821
|
-
function roundFloat(val) {
|
|
9822
|
-
return Math.floor(val * 100) / 100;
|
|
9823
|
-
}
|
|
9824
|
-
|
|
9825
|
-
function addValue(obj, key, val) {
|
|
9826
|
-
obj[key] = (obj[key] || 0) + val;
|
|
9827
|
-
}
|
|
9828
|
-
|
|
9829
|
-
// Composite/text components don't have any built-in ID: we have to make our own
|
|
9830
|
-
var compositeIDMap;
|
|
9831
|
-
var compositeIDCounter = 17000;
|
|
9832
|
-
function getIDOfComposite(inst) {
|
|
9833
|
-
if (!compositeIDMap) {
|
|
9834
|
-
compositeIDMap = new WeakMap();
|
|
9835
|
-
}
|
|
9836
|
-
if (compositeIDMap.has(inst)) {
|
|
9837
|
-
return compositeIDMap.get(inst);
|
|
9838
|
-
} else {
|
|
9839
|
-
var id = compositeIDCounter++;
|
|
9840
|
-
compositeIDMap.set(inst, id);
|
|
9841
|
-
return id;
|
|
9842
|
-
}
|
|
9843
|
-
}
|
|
9844
|
-
|
|
9845
|
-
function getID(inst) {
|
|
9846
|
-
if (inst.hasOwnProperty('_rootNodeID')) {
|
|
9847
|
-
return inst._rootNodeID;
|
|
9848
|
-
} else {
|
|
9849
|
-
return getIDOfComposite(inst);
|
|
9850
|
-
}
|
|
9851
|
-
}
|
|
9852
|
-
|
|
9853
|
-
function stripComplexValues(key, value) {
|
|
9854
|
-
if (typeof value !== 'object' || Array.isArray(value) || value == null) {
|
|
9855
|
-
return value;
|
|
9856
|
-
}
|
|
9857
|
-
var prototype = Object.getPrototypeOf(value);
|
|
9858
|
-
if (!prototype || prototype === Object.prototype) {
|
|
9859
|
-
return value;
|
|
9860
|
-
}
|
|
9861
|
-
return '<not serializable>';
|
|
9862
|
-
}
|
|
9863
|
-
|
|
9864
|
-
// This implementation of ReactPerf is going away some time mid 15.x.
|
|
9865
|
-
// While we plan to keep most of the API, the actual format of measurements
|
|
9866
|
-
// will change dramatically. To signal this, we wrap them into an opaque-ish
|
|
9867
|
-
// object to discourage reaching into it until the API stabilizes.
|
|
9868
|
-
function wrapLegacyMeasurements(measurements) {
|
|
9869
|
-
return { __unstable_this_format_will_change: measurements };
|
|
9870
|
-
}
|
|
9871
|
-
function unwrapLegacyMeasurements(measurements) {
|
|
9872
|
-
return measurements && measurements.__unstable_this_format_will_change || measurements;
|
|
9873
|
-
}
|
|
9874
|
-
|
|
9875
|
-
var warnedAboutPrintDOM = false;
|
|
9876
|
-
var warnedAboutGetMeasurementsSummaryMap = false;
|
|
9877
|
-
|
|
9878
|
-
var ReactDefaultPerf = {
|
|
9879
|
-
_allMeasurements: [], // last item in the list is the current one
|
|
9880
|
-
_mountStack: [0],
|
|
9881
|
-
_compositeStack: [],
|
|
9882
|
-
_injected: false,
|
|
9883
|
-
|
|
9884
|
-
start: function () {
|
|
9885
|
-
if (!ReactDefaultPerf._injected) {
|
|
9886
|
-
ReactPerf.injection.injectMeasure(ReactDefaultPerf.measure);
|
|
9887
|
-
}
|
|
9888
|
-
|
|
9889
|
-
ReactDefaultPerf._allMeasurements.length = 0;
|
|
9890
|
-
ReactPerf.enableMeasure = true;
|
|
9891
|
-
},
|
|
9892
|
-
|
|
9893
|
-
stop: function () {
|
|
9894
|
-
ReactPerf.enableMeasure = false;
|
|
9895
|
-
},
|
|
9896
|
-
|
|
9897
|
-
getLastMeasurements: function () {
|
|
9898
|
-
return wrapLegacyMeasurements(ReactDefaultPerf._allMeasurements);
|
|
9899
|
-
},
|
|
9900
|
-
|
|
9901
|
-
printExclusive: function (measurements) {
|
|
9902
|
-
measurements = unwrapLegacyMeasurements(measurements || ReactDefaultPerf._allMeasurements);
|
|
9903
|
-
var summary = ReactDefaultPerfAnalysis.getExclusiveSummary(measurements);
|
|
9904
|
-
console.table(summary.map(function (item) {
|
|
9905
|
-
return {
|
|
9906
|
-
'Component class name': item.componentName,
|
|
9907
|
-
'Total inclusive time (ms)': roundFloat(item.inclusive),
|
|
9908
|
-
'Exclusive mount time (ms)': roundFloat(item.exclusive),
|
|
9909
|
-
'Exclusive render time (ms)': roundFloat(item.render),
|
|
9910
|
-
'Mount time per instance (ms)': roundFloat(item.exclusive / item.count),
|
|
9911
|
-
'Render time per instance (ms)': roundFloat(item.render / item.count),
|
|
9912
|
-
'Instances': item.count
|
|
9913
|
-
};
|
|
9914
|
-
}));
|
|
9915
|
-
// TODO: ReactDefaultPerfAnalysis.getTotalTime() does not return the correct
|
|
9916
|
-
// number.
|
|
9917
|
-
},
|
|
9918
|
-
|
|
9919
|
-
printInclusive: function (measurements) {
|
|
9920
|
-
measurements = unwrapLegacyMeasurements(measurements || ReactDefaultPerf._allMeasurements);
|
|
9921
|
-
var summary = ReactDefaultPerfAnalysis.getInclusiveSummary(measurements);
|
|
9922
|
-
console.table(summary.map(function (item) {
|
|
9923
|
-
return {
|
|
9924
|
-
'Owner > component': item.componentName,
|
|
9925
|
-
'Inclusive time (ms)': roundFloat(item.time),
|
|
9926
|
-
'Instances': item.count
|
|
9927
|
-
};
|
|
9928
|
-
}));
|
|
9929
|
-
console.log('Total time:', ReactDefaultPerfAnalysis.getTotalTime(measurements).toFixed(2) + ' ms');
|
|
9930
|
-
},
|
|
9931
|
-
|
|
9932
|
-
getMeasurementsSummaryMap: function (measurements) {
|
|
9933
|
-
"development" !== 'production' ? warning(warnedAboutGetMeasurementsSummaryMap, '`ReactPerf.getMeasurementsSummaryMap(...)` is deprecated. Use ' + '`ReactPerf.getWasted(...)` instead.') : void 0;
|
|
9934
|
-
warnedAboutGetMeasurementsSummaryMap = true;
|
|
9935
|
-
return ReactDefaultPerf.getWasted(measurements);
|
|
9936
|
-
},
|
|
9937
|
-
|
|
9938
|
-
getWasted: function (measurements) {
|
|
9939
|
-
measurements = unwrapLegacyMeasurements(measurements);
|
|
9940
|
-
var summary = ReactDefaultPerfAnalysis.getInclusiveSummary(measurements, true);
|
|
9941
|
-
return summary.map(function (item) {
|
|
9942
|
-
return {
|
|
9943
|
-
'Owner > component': item.componentName,
|
|
9944
|
-
'Wasted time (ms)': item.time,
|
|
9945
|
-
'Instances': item.count
|
|
9946
|
-
};
|
|
9947
|
-
});
|
|
9948
|
-
},
|
|
9949
|
-
|
|
9950
|
-
printWasted: function (measurements) {
|
|
9951
|
-
measurements = unwrapLegacyMeasurements(measurements || ReactDefaultPerf._allMeasurements);
|
|
9952
|
-
console.table(ReactDefaultPerf.getWasted(measurements));
|
|
9953
|
-
console.log('Total time:', ReactDefaultPerfAnalysis.getTotalTime(measurements).toFixed(2) + ' ms');
|
|
9954
|
-
},
|
|
9955
|
-
|
|
9956
|
-
printDOM: function (measurements) {
|
|
9957
|
-
"development" !== 'production' ? warning(warnedAboutPrintDOM, '`ReactPerf.printDOM(...)` is deprecated. Use ' + '`ReactPerf.printOperations(...)` instead.') : void 0;
|
|
9958
|
-
warnedAboutPrintDOM = true;
|
|
9959
|
-
return ReactDefaultPerf.printOperations(measurements);
|
|
9960
|
-
},
|
|
9961
|
-
|
|
9962
|
-
printOperations: function (measurements) {
|
|
9963
|
-
measurements = unwrapLegacyMeasurements(measurements || ReactDefaultPerf._allMeasurements);
|
|
9964
|
-
var summary = ReactDefaultPerfAnalysis.getDOMSummary(measurements);
|
|
9965
|
-
console.table(summary.map(function (item) {
|
|
9966
|
-
var result = {};
|
|
9967
|
-
result[DOMProperty.ID_ATTRIBUTE_NAME] = item.id;
|
|
9968
|
-
result.type = item.type;
|
|
9969
|
-
result.args = JSON.stringify(item.args, stripComplexValues);
|
|
9970
|
-
return result;
|
|
9971
|
-
}));
|
|
9972
|
-
console.log('Total time:', ReactDefaultPerfAnalysis.getTotalTime(measurements).toFixed(2) + ' ms');
|
|
9973
|
-
},
|
|
9974
|
-
|
|
9975
|
-
_recordWrite: function (id, fnName, totalTime, args) {
|
|
9976
|
-
// TODO: totalTime isn't that useful since it doesn't count paints/reflows
|
|
9977
|
-
var entry = ReactDefaultPerf._allMeasurements[ReactDefaultPerf._allMeasurements.length - 1];
|
|
9978
|
-
var writes = entry.writes;
|
|
9979
|
-
writes[id] = writes[id] || [];
|
|
9980
|
-
writes[id].push({
|
|
9981
|
-
type: fnName,
|
|
9982
|
-
time: totalTime,
|
|
9983
|
-
args: args
|
|
9984
|
-
});
|
|
9985
|
-
},
|
|
9986
|
-
|
|
9987
|
-
measure: function (moduleName, fnName, func) {
|
|
9988
|
-
return function () {
|
|
9989
|
-
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
|
|
9990
|
-
args[_key] = arguments[_key];
|
|
9991
|
-
}
|
|
9992
|
-
|
|
9993
|
-
var totalTime;
|
|
9994
|
-
var rv;
|
|
9995
|
-
var start;
|
|
9996
|
-
|
|
9997
|
-
var entry = ReactDefaultPerf._allMeasurements[ReactDefaultPerf._allMeasurements.length - 1];
|
|
9998
|
-
|
|
9999
|
-
if (fnName === '_renderNewRootComponent' || fnName === 'flushBatchedUpdates') {
|
|
10000
|
-
// A "measurement" is a set of metrics recorded for each flush. We want
|
|
10001
|
-
// to group the metrics for a given flush together so we can look at the
|
|
10002
|
-
// components that rendered and the DOM operations that actually
|
|
10003
|
-
// happened to determine the amount of "wasted work" performed.
|
|
10004
|
-
ReactDefaultPerf._allMeasurements.push(entry = {
|
|
10005
|
-
exclusive: {},
|
|
10006
|
-
inclusive: {},
|
|
10007
|
-
render: {},
|
|
10008
|
-
counts: {},
|
|
10009
|
-
writes: {},
|
|
10010
|
-
displayNames: {},
|
|
10011
|
-
hierarchy: {},
|
|
10012
|
-
totalTime: 0,
|
|
10013
|
-
created: {}
|
|
10014
|
-
});
|
|
10015
|
-
start = performanceNow();
|
|
10016
|
-
rv = func.apply(this, args);
|
|
10017
|
-
entry.totalTime = performanceNow() - start;
|
|
10018
|
-
return rv;
|
|
10019
|
-
} else if (fnName === '_mountImageIntoNode' || moduleName === 'ReactDOMIDOperations' || moduleName === 'CSSPropertyOperations' || moduleName === 'DOMChildrenOperations' || moduleName === 'DOMPropertyOperations' || moduleName === 'ReactComponentBrowserEnvironment') {
|
|
10020
|
-
start = performanceNow();
|
|
10021
|
-
rv = func.apply(this, args);
|
|
10022
|
-
totalTime = performanceNow() - start;
|
|
10023
|
-
|
|
10024
|
-
if (fnName === '_mountImageIntoNode') {
|
|
10025
|
-
ReactDefaultPerf._recordWrite('', fnName, totalTime, args[0]);
|
|
10026
|
-
} else if (fnName === 'dangerouslyProcessChildrenUpdates') {
|
|
10027
|
-
// special format
|
|
10028
|
-
args[1].forEach(function (update) {
|
|
10029
|
-
var writeArgs = {};
|
|
10030
|
-
if (update.fromIndex !== null) {
|
|
10031
|
-
writeArgs.fromIndex = update.fromIndex;
|
|
10032
|
-
}
|
|
10033
|
-
if (update.toIndex !== null) {
|
|
10034
|
-
writeArgs.toIndex = update.toIndex;
|
|
10035
|
-
}
|
|
10036
|
-
if (update.content !== null) {
|
|
10037
|
-
writeArgs.content = update.content;
|
|
10038
|
-
}
|
|
10039
|
-
ReactDefaultPerf._recordWrite(args[0]._rootNodeID, update.type, totalTime, writeArgs);
|
|
10040
|
-
});
|
|
10041
|
-
} else {
|
|
10042
|
-
// basic format
|
|
10043
|
-
var id = args[0];
|
|
10044
|
-
if (moduleName === 'EventPluginHub') {
|
|
10045
|
-
id = id._rootNodeID;
|
|
10046
|
-
} else if (fnName === 'replaceNodeWithMarkup') {
|
|
10047
|
-
// Old node is already unmounted; can't get its instance
|
|
10048
|
-
id = ReactDOMComponentTree.getInstanceFromNode(args[1].node)._rootNodeID;
|
|
10049
|
-
} else if (fnName === 'replaceDelimitedText') {
|
|
10050
|
-
id = getID(ReactDOMComponentTree.getInstanceFromNode(args[0]));
|
|
10051
|
-
} else if (typeof id === 'object') {
|
|
10052
|
-
id = getID(ReactDOMComponentTree.getInstanceFromNode(args[0]));
|
|
10053
|
-
}
|
|
10054
|
-
ReactDefaultPerf._recordWrite(id, fnName, totalTime, Array.prototype.slice.call(args, 1));
|
|
10055
|
-
}
|
|
10056
|
-
return rv;
|
|
10057
|
-
} else if (moduleName === 'ReactCompositeComponent' && (fnName === 'mountComponent' || fnName === 'updateComponent' || // TODO: receiveComponent()?
|
|
10058
|
-
fnName === '_renderValidatedComponent')) {
|
|
10059
|
-
|
|
10060
|
-
if (this._currentElement.type === ReactMount.TopLevelWrapper) {
|
|
10061
|
-
return func.apply(this, args);
|
|
10062
|
-
}
|
|
10063
|
-
|
|
10064
|
-
var rootNodeID = getIDOfComposite(this);
|
|
10065
|
-
var isRender = fnName === '_renderValidatedComponent';
|
|
10066
|
-
var isMount = fnName === 'mountComponent';
|
|
10067
|
-
|
|
10068
|
-
var mountStack = ReactDefaultPerf._mountStack;
|
|
10069
|
-
|
|
10070
|
-
if (isRender) {
|
|
10071
|
-
addValue(entry.counts, rootNodeID, 1);
|
|
10072
|
-
} else if (isMount) {
|
|
10073
|
-
entry.created[rootNodeID] = true;
|
|
10074
|
-
mountStack.push(0);
|
|
10075
|
-
}
|
|
10076
|
-
|
|
10077
|
-
ReactDefaultPerf._compositeStack.push(rootNodeID);
|
|
10078
|
-
|
|
10079
|
-
start = performanceNow();
|
|
10080
|
-
rv = func.apply(this, args);
|
|
10081
|
-
totalTime = performanceNow() - start;
|
|
10082
|
-
|
|
10083
|
-
ReactDefaultPerf._compositeStack.pop();
|
|
10084
|
-
|
|
10085
|
-
if (isRender) {
|
|
10086
|
-
addValue(entry.render, rootNodeID, totalTime);
|
|
10087
|
-
} else if (isMount) {
|
|
10088
|
-
var subMountTime = mountStack.pop();
|
|
10089
|
-
mountStack[mountStack.length - 1] += totalTime;
|
|
10090
|
-
addValue(entry.exclusive, rootNodeID, totalTime - subMountTime);
|
|
10091
|
-
addValue(entry.inclusive, rootNodeID, totalTime);
|
|
10092
|
-
} else {
|
|
10093
|
-
addValue(entry.inclusive, rootNodeID, totalTime);
|
|
10094
|
-
}
|
|
10095
|
-
|
|
10096
|
-
entry.displayNames[rootNodeID] = {
|
|
10097
|
-
current: this.getName(),
|
|
10098
|
-
owner: this._currentElement._owner ? this._currentElement._owner.getName() : '<root>'
|
|
10099
|
-
};
|
|
10100
|
-
|
|
10101
|
-
return rv;
|
|
10102
|
-
} else if ((moduleName === 'ReactDOMComponent' || moduleName === 'ReactDOMTextComponent') && (fnName === 'mountComponent' || fnName === 'receiveComponent')) {
|
|
10103
|
-
|
|
10104
|
-
rv = func.apply(this, args);
|
|
10105
|
-
entry.hierarchy[getID(this)] = ReactDefaultPerf._compositeStack.slice();
|
|
10106
|
-
return rv;
|
|
10107
|
-
} else {
|
|
10108
|
-
return func.apply(this, args);
|
|
10109
|
-
}
|
|
10110
|
-
};
|
|
10111
|
-
}
|
|
10112
|
-
};
|
|
10113
|
-
|
|
10114
|
-
module.exports = ReactDefaultPerf;
|
|
10115
|
-
},{"10":10,"181":181,"183":183,"44":44,"65":65,"81":81,"88":88}],65:[function(_dereq_,module,exports){
|
|
10116
|
-
/**
|
|
10117
|
-
* Copyright 2013-present, Facebook, Inc.
|
|
10118
|
-
* All rights reserved.
|
|
10119
|
-
*
|
|
10120
|
-
* This source code is licensed under the BSD-style license found in the
|
|
10121
|
-
* LICENSE file in the root directory of this source tree. An additional grant
|
|
10122
|
-
* of patent rights can be found in the PATENTS file in the same directory.
|
|
10123
|
-
*
|
|
10124
|
-
* @providesModule ReactDefaultPerfAnalysis
|
|
10125
|
-
*/
|
|
10126
|
-
|
|
10127
|
-
'use strict';
|
|
10128
|
-
|
|
10129
|
-
// Don't try to save users less than 1.2ms (a number I made up)
|
|
10130
|
-
|
|
10131
|
-
var _assign = _dereq_(184);
|
|
10132
|
-
|
|
10133
|
-
var DONT_CARE_THRESHOLD = 1.2;
|
|
10134
|
-
var DOM_OPERATION_TYPES = {
|
|
10135
|
-
'_mountImageIntoNode': 'set innerHTML',
|
|
10136
|
-
INSERT_MARKUP: 'set innerHTML',
|
|
10137
|
-
MOVE_EXISTING: 'move',
|
|
10138
|
-
REMOVE_NODE: 'remove',
|
|
10139
|
-
SET_MARKUP: 'set innerHTML',
|
|
10140
|
-
TEXT_CONTENT: 'set textContent',
|
|
10141
|
-
'setValueForProperty': 'update attribute',
|
|
10142
|
-
'setValueForAttribute': 'update attribute',
|
|
10143
|
-
'deleteValueForProperty': 'remove attribute',
|
|
10144
|
-
'setValueForStyles': 'update styles',
|
|
10145
|
-
'replaceNodeWithMarkup': 'replace',
|
|
10146
|
-
'replaceDelimitedText': 'replace'
|
|
10147
|
-
};
|
|
10148
|
-
|
|
10149
|
-
function getTotalTime(measurements) {
|
|
10150
|
-
// TODO: return number of DOM ops? could be misleading.
|
|
10151
|
-
// TODO: measure dropped frames after reconcile?
|
|
10152
|
-
// TODO: log total time of each reconcile and the top-level component
|
|
10153
|
-
// class that triggered it.
|
|
10154
|
-
var totalTime = 0;
|
|
10155
|
-
for (var i = 0; i < measurements.length; i++) {
|
|
10156
|
-
var measurement = measurements[i];
|
|
10157
|
-
totalTime += measurement.totalTime;
|
|
10158
|
-
}
|
|
10159
|
-
return totalTime;
|
|
10160
|
-
}
|
|
10161
|
-
|
|
10162
|
-
function getDOMSummary(measurements) {
|
|
10163
|
-
var items = [];
|
|
10164
|
-
measurements.forEach(function (measurement) {
|
|
10165
|
-
Object.keys(measurement.writes).forEach(function (id) {
|
|
10166
|
-
measurement.writes[id].forEach(function (write) {
|
|
10167
|
-
items.push({
|
|
10168
|
-
id: id,
|
|
10169
|
-
type: DOM_OPERATION_TYPES[write.type] || write.type,
|
|
10170
|
-
args: write.args
|
|
10171
|
-
});
|
|
10172
|
-
});
|
|
10173
|
-
});
|
|
10174
|
-
});
|
|
10175
|
-
return items;
|
|
10176
|
-
}
|
|
10177
|
-
|
|
10178
|
-
function getExclusiveSummary(measurements) {
|
|
10179
|
-
var candidates = {};
|
|
10180
|
-
var displayName;
|
|
10181
|
-
|
|
10182
|
-
for (var i = 0; i < measurements.length; i++) {
|
|
10183
|
-
var measurement = measurements[i];
|
|
10184
|
-
var allIDs = _assign({}, measurement.exclusive, measurement.inclusive);
|
|
10185
|
-
|
|
10186
|
-
for (var id in allIDs) {
|
|
10187
|
-
displayName = measurement.displayNames[id].current;
|
|
10188
|
-
|
|
10189
|
-
candidates[displayName] = candidates[displayName] || {
|
|
10190
|
-
componentName: displayName,
|
|
10191
|
-
inclusive: 0,
|
|
10192
|
-
exclusive: 0,
|
|
10193
|
-
render: 0,
|
|
10194
|
-
count: 0
|
|
10195
|
-
};
|
|
10196
|
-
if (measurement.render[id]) {
|
|
10197
|
-
candidates[displayName].render += measurement.render[id];
|
|
10198
|
-
}
|
|
10199
|
-
if (measurement.exclusive[id]) {
|
|
10200
|
-
candidates[displayName].exclusive += measurement.exclusive[id];
|
|
10201
|
-
}
|
|
10202
|
-
if (measurement.inclusive[id]) {
|
|
10203
|
-
candidates[displayName].inclusive += measurement.inclusive[id];
|
|
10204
|
-
}
|
|
10205
|
-
if (measurement.counts[id]) {
|
|
10206
|
-
candidates[displayName].count += measurement.counts[id];
|
|
10207
|
-
}
|
|
10208
|
-
}
|
|
10209
|
-
}
|
|
10210
|
-
|
|
10211
|
-
// Now make a sorted array with the results.
|
|
10212
|
-
var arr = [];
|
|
10213
|
-
for (displayName in candidates) {
|
|
10214
|
-
if (candidates[displayName].exclusive >= DONT_CARE_THRESHOLD) {
|
|
10215
|
-
arr.push(candidates[displayName]);
|
|
10216
|
-
}
|
|
10217
|
-
}
|
|
10218
|
-
|
|
10219
|
-
arr.sort(function (a, b) {
|
|
10220
|
-
return b.exclusive - a.exclusive;
|
|
10221
|
-
});
|
|
10222
|
-
|
|
10223
|
-
return arr;
|
|
10224
|
-
}
|
|
10225
|
-
|
|
10226
|
-
function getInclusiveSummary(measurements, onlyClean) {
|
|
10227
|
-
var candidates = {};
|
|
10228
|
-
var inclusiveKey;
|
|
10229
|
-
|
|
10230
|
-
for (var i = 0; i < measurements.length; i++) {
|
|
10231
|
-
var measurement = measurements[i];
|
|
10232
|
-
var allIDs = _assign({}, measurement.exclusive, measurement.inclusive);
|
|
10233
|
-
var cleanComponents;
|
|
10234
|
-
|
|
10235
|
-
if (onlyClean) {
|
|
10236
|
-
cleanComponents = getUnchangedComponents(measurement);
|
|
10237
|
-
}
|
|
10238
|
-
|
|
10239
|
-
for (var id in allIDs) {
|
|
10240
|
-
if (onlyClean && !cleanComponents[id]) {
|
|
10241
|
-
continue;
|
|
10242
|
-
}
|
|
10243
|
-
|
|
10244
|
-
var displayName = measurement.displayNames[id];
|
|
10245
|
-
|
|
10246
|
-
// Inclusive time is not useful for many components without knowing where
|
|
10247
|
-
// they are instantiated. So we aggregate inclusive time with both the
|
|
10248
|
-
// owner and current displayName as the key.
|
|
10249
|
-
inclusiveKey = displayName.owner + ' > ' + displayName.current;
|
|
10250
|
-
|
|
10251
|
-
candidates[inclusiveKey] = candidates[inclusiveKey] || {
|
|
10252
|
-
componentName: inclusiveKey,
|
|
10253
|
-
time: 0,
|
|
10254
|
-
count: 0
|
|
10255
|
-
};
|
|
10256
|
-
|
|
10257
|
-
if (measurement.inclusive[id]) {
|
|
10258
|
-
candidates[inclusiveKey].time += measurement.inclusive[id];
|
|
10259
|
-
}
|
|
10260
|
-
if (measurement.counts[id]) {
|
|
10261
|
-
candidates[inclusiveKey].count += measurement.counts[id];
|
|
10262
|
-
}
|
|
10263
|
-
}
|
|
10264
|
-
}
|
|
10265
|
-
|
|
10266
|
-
// Now make a sorted array with the results.
|
|
10267
|
-
var arr = [];
|
|
10268
|
-
for (inclusiveKey in candidates) {
|
|
10269
|
-
if (candidates[inclusiveKey].time >= DONT_CARE_THRESHOLD) {
|
|
10270
|
-
arr.push(candidates[inclusiveKey]);
|
|
10271
|
-
}
|
|
10272
|
-
}
|
|
10273
|
-
|
|
10274
|
-
arr.sort(function (a, b) {
|
|
10275
|
-
return b.time - a.time;
|
|
10276
|
-
});
|
|
10277
|
-
|
|
10278
|
-
return arr;
|
|
10279
|
-
}
|
|
10280
|
-
|
|
10281
|
-
function getUnchangedComponents(measurement) {
|
|
10282
|
-
// For a given reconcile, look at which components did not actually
|
|
10283
|
-
// render anything to the DOM and return a mapping of their ID to
|
|
10284
|
-
// the amount of time it took to render the entire subtree.
|
|
10285
|
-
var cleanComponents = {};
|
|
10286
|
-
var writes = measurement.writes;
|
|
10287
|
-
var hierarchy = measurement.hierarchy;
|
|
10288
|
-
var dirtyComposites = {};
|
|
10289
|
-
Object.keys(writes).forEach(function (id) {
|
|
10290
|
-
writes[id].forEach(function (write) {
|
|
10291
|
-
// Root mounting (innerHTML set) is recorded with an ID of ''
|
|
10292
|
-
if (id !== '' && hierarchy.hasOwnProperty(id)) {
|
|
10293
|
-
hierarchy[id].forEach(function (c) {
|
|
10294
|
-
return dirtyComposites[c] = true;
|
|
10295
|
-
});
|
|
10296
|
-
}
|
|
10297
|
-
});
|
|
10298
|
-
});
|
|
10299
|
-
var allIDs = _assign({}, measurement.exclusive, measurement.inclusive);
|
|
10300
|
-
|
|
10301
|
-
for (var id in allIDs) {
|
|
10302
|
-
var isDirty = false;
|
|
10303
|
-
// See if any of the DOM operations applied to this component's subtree.
|
|
10304
|
-
if (dirtyComposites[id]) {
|
|
10305
|
-
isDirty = true;
|
|
10306
|
-
}
|
|
10307
|
-
// check if component newly created
|
|
10308
|
-
if (measurement.created[id]) {
|
|
10309
|
-
isDirty = true;
|
|
10310
|
-
}
|
|
10311
|
-
if (!isDirty && measurement.counts[id] > 0) {
|
|
10312
|
-
cleanComponents[id] = true;
|
|
10313
|
-
}
|
|
10314
|
-
}
|
|
10315
|
-
return cleanComponents;
|
|
10316
|
-
}
|
|
10317
|
-
|
|
10318
|
-
var ReactDefaultPerfAnalysis = {
|
|
10319
|
-
getExclusiveSummary: getExclusiveSummary,
|
|
10320
|
-
getInclusiveSummary: getInclusiveSummary,
|
|
10321
|
-
getDOMSummary: getDOMSummary,
|
|
10322
|
-
getTotalTime: getTotalTime
|
|
10323
|
-
};
|
|
10324
|
-
|
|
10325
|
-
module.exports = ReactDefaultPerfAnalysis;
|
|
10326
|
-
},{"184":184}],66:[function(_dereq_,module,exports){
|
|
10345
|
+
},{"108":108,"109":109,"110":110,"13":13,"15":15,"2":2,"22":22,"35":35,"43":43,"45":45,"48":48,"58":58,"6":6,"60":60,"63":63,"70":70,"73":73,"92":92}],65:[function(_dereq_,module,exports){
|
|
10327
10346
|
/**
|
|
10328
10347
|
* Copyright 2014-present, Facebook, Inc.
|
|
10329
10348
|
* All rights reserved.
|
|
@@ -10339,7 +10358,7 @@ module.exports = ReactDefaultPerfAnalysis;
|
|
|
10339
10358
|
|
|
10340
10359
|
var _assign = _dereq_(184);
|
|
10341
10360
|
|
|
10342
|
-
var ReactCurrentOwner = _dereq_(
|
|
10361
|
+
var ReactCurrentOwner = _dereq_(40);
|
|
10343
10362
|
|
|
10344
10363
|
var warning = _dereq_(183);
|
|
10345
10364
|
var canDefineProperty = _dereq_(128);
|
|
@@ -10439,6 +10458,10 @@ var ReactElement = function (type, key, ref, self, source, owner, props) {
|
|
|
10439
10458
|
return element;
|
|
10440
10459
|
};
|
|
10441
10460
|
|
|
10461
|
+
/**
|
|
10462
|
+
* Create and return a new ReactElement of the given type.
|
|
10463
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.createelement
|
|
10464
|
+
*/
|
|
10442
10465
|
ReactElement.createElement = function (type, config, children) {
|
|
10443
10466
|
var propName;
|
|
10444
10467
|
|
|
@@ -10452,6 +10475,11 @@ ReactElement.createElement = function (type, config, children) {
|
|
|
10452
10475
|
|
|
10453
10476
|
if (config != null) {
|
|
10454
10477
|
if ("development" !== 'production') {
|
|
10478
|
+
"development" !== 'production' ? warning(
|
|
10479
|
+
/* eslint-disable no-proto */
|
|
10480
|
+
config.__proto__ == null || config.__proto__ === Object.prototype,
|
|
10481
|
+
/* eslint-enable no-proto */
|
|
10482
|
+
'React.createElement(...): Expected props argument to be a plain object. ' + 'Properties defined in its prototype chain will be ignored.') : void 0;
|
|
10455
10483
|
ref = !config.hasOwnProperty('ref') || Object.getOwnPropertyDescriptor(config, 'ref').get ? null : config.ref;
|
|
10456
10484
|
key = !config.hasOwnProperty('key') || Object.getOwnPropertyDescriptor(config, 'key').get ? null : '' + config.key;
|
|
10457
10485
|
} else {
|
|
@@ -10523,6 +10551,10 @@ ReactElement.createElement = function (type, config, children) {
|
|
|
10523
10551
|
return ReactElement(type, key, ref, self, source, ReactCurrentOwner.current, props);
|
|
10524
10552
|
};
|
|
10525
10553
|
|
|
10554
|
+
/**
|
|
10555
|
+
* Return a function that produces ReactElements of a given type.
|
|
10556
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.createfactory
|
|
10557
|
+
*/
|
|
10526
10558
|
ReactElement.createFactory = function (type) {
|
|
10527
10559
|
var factory = ReactElement.createElement.bind(null, type);
|
|
10528
10560
|
// Expose the type on the factory and the prototype so that it can be
|
|
@@ -10540,6 +10572,10 @@ ReactElement.cloneAndReplaceKey = function (oldElement, newKey) {
|
|
|
10540
10572
|
return newElement;
|
|
10541
10573
|
};
|
|
10542
10574
|
|
|
10575
|
+
/**
|
|
10576
|
+
* Clone and return a new ReactElement using element as the starting point.
|
|
10577
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.cloneelement
|
|
10578
|
+
*/
|
|
10543
10579
|
ReactElement.cloneElement = function (element, config, children) {
|
|
10544
10580
|
var propName;
|
|
10545
10581
|
|
|
@@ -10560,6 +10596,13 @@ ReactElement.cloneElement = function (element, config, children) {
|
|
|
10560
10596
|
var owner = element._owner;
|
|
10561
10597
|
|
|
10562
10598
|
if (config != null) {
|
|
10599
|
+
if ("development" !== 'production') {
|
|
10600
|
+
"development" !== 'production' ? warning(
|
|
10601
|
+
/* eslint-disable no-proto */
|
|
10602
|
+
config.__proto__ == null || config.__proto__ === Object.prototype,
|
|
10603
|
+
/* eslint-enable no-proto */
|
|
10604
|
+
'React.cloneElement(...): Expected props argument to be a plain object. ' + 'Properties defined in its prototype chain will be ignored.') : void 0;
|
|
10605
|
+
}
|
|
10563
10606
|
if (config.ref !== undefined) {
|
|
10564
10607
|
// Silently steal the ref from the parent.
|
|
10565
10608
|
ref = config.ref;
|
|
@@ -10602,6 +10645,8 @@ ReactElement.cloneElement = function (element, config, children) {
|
|
|
10602
10645
|
};
|
|
10603
10646
|
|
|
10604
10647
|
/**
|
|
10648
|
+
* Verifies the object is a ReactElement.
|
|
10649
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.isvalidelement
|
|
10605
10650
|
* @param {?object} object
|
|
10606
10651
|
* @return {boolean} True if `object` is a valid component.
|
|
10607
10652
|
* @final
|
|
@@ -10611,7 +10656,7 @@ ReactElement.isValidElement = function (object) {
|
|
|
10611
10656
|
};
|
|
10612
10657
|
|
|
10613
10658
|
module.exports = ReactElement;
|
|
10614
|
-
},{"128":128,"183":183,"184":184,"
|
|
10659
|
+
},{"128":128,"183":183,"184":184,"40":40}],66:[function(_dereq_,module,exports){
|
|
10615
10660
|
/**
|
|
10616
10661
|
* Copyright 2014-present, Facebook, Inc.
|
|
10617
10662
|
* All rights reserved.
|
|
@@ -10632,10 +10677,10 @@ module.exports = ReactElement;
|
|
|
10632
10677
|
|
|
10633
10678
|
'use strict';
|
|
10634
10679
|
|
|
10635
|
-
var ReactElement = _dereq_(
|
|
10680
|
+
var ReactElement = _dereq_(65);
|
|
10636
10681
|
var ReactPropTypeLocations = _dereq_(90);
|
|
10637
10682
|
var ReactPropTypeLocationNames = _dereq_(89);
|
|
10638
|
-
var ReactCurrentOwner = _dereq_(
|
|
10683
|
+
var ReactCurrentOwner = _dereq_(40);
|
|
10639
10684
|
|
|
10640
10685
|
var canDefineProperty = _dereq_(128);
|
|
10641
10686
|
var getIteratorFn = _dereq_(139);
|
|
@@ -10893,7 +10938,7 @@ var ReactElementValidator = {
|
|
|
10893
10938
|
};
|
|
10894
10939
|
|
|
10895
10940
|
module.exports = ReactElementValidator;
|
|
10896
|
-
},{"128":128,"139":139,"173":173,"183":183,"
|
|
10941
|
+
},{"128":128,"139":139,"173":173,"183":183,"40":40,"65":65,"89":89,"90":90}],67:[function(_dereq_,module,exports){
|
|
10897
10942
|
/**
|
|
10898
10943
|
* Copyright 2014-present, Facebook, Inc.
|
|
10899
10944
|
* All rights reserved.
|
|
@@ -10924,7 +10969,7 @@ var ReactEmptyComponent = {
|
|
|
10924
10969
|
ReactEmptyComponent.injection = ReactEmptyComponentInjection;
|
|
10925
10970
|
|
|
10926
10971
|
module.exports = ReactEmptyComponent;
|
|
10927
|
-
},{}],
|
|
10972
|
+
},{}],68:[function(_dereq_,module,exports){
|
|
10928
10973
|
/**
|
|
10929
10974
|
* Copyright 2013-present, Facebook, Inc.
|
|
10930
10975
|
* All rights reserved.
|
|
@@ -11001,7 +11046,7 @@ if ("development" !== 'production') {
|
|
|
11001
11046
|
}
|
|
11002
11047
|
|
|
11003
11048
|
module.exports = ReactErrorUtils;
|
|
11004
|
-
},{}],
|
|
11049
|
+
},{}],69:[function(_dereq_,module,exports){
|
|
11005
11050
|
/**
|
|
11006
11051
|
* Copyright 2013-present, Facebook, Inc.
|
|
11007
11052
|
* All rights reserved.
|
|
@@ -11035,7 +11080,7 @@ var ReactEventEmitterMixin = {
|
|
|
11035
11080
|
};
|
|
11036
11081
|
|
|
11037
11082
|
module.exports = ReactEventEmitterMixin;
|
|
11038
|
-
},{"17":17}],
|
|
11083
|
+
},{"17":17}],70:[function(_dereq_,module,exports){
|
|
11039
11084
|
/**
|
|
11040
11085
|
* Copyright 2013-present, Facebook, Inc.
|
|
11041
11086
|
* All rights reserved.
|
|
@@ -11054,7 +11099,7 @@ var _assign = _dereq_(184);
|
|
|
11054
11099
|
var EventListener = _dereq_(158);
|
|
11055
11100
|
var ExecutionEnvironment = _dereq_(159);
|
|
11056
11101
|
var PooledClass = _dereq_(26);
|
|
11057
|
-
var ReactDOMComponentTree = _dereq_(
|
|
11102
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
11058
11103
|
var ReactUpdates = _dereq_(104);
|
|
11059
11104
|
|
|
11060
11105
|
var getEventTarget = _dereq_(138);
|
|
@@ -11193,7 +11238,7 @@ var ReactEventListener = {
|
|
|
11193
11238
|
};
|
|
11194
11239
|
|
|
11195
11240
|
module.exports = ReactEventListener;
|
|
11196
|
-
},{"104":104,"138":138,"158":158,"159":159,"170":170,"184":184,"26":26,"
|
|
11241
|
+
},{"104":104,"138":138,"158":158,"159":159,"170":170,"184":184,"26":26,"45":45}],71:[function(_dereq_,module,exports){
|
|
11197
11242
|
/**
|
|
11198
11243
|
* Copyright 2013-present, Facebook, Inc.
|
|
11199
11244
|
* All rights reserved.
|
|
@@ -11215,7 +11260,7 @@ var ReactFeatureFlags = {
|
|
|
11215
11260
|
};
|
|
11216
11261
|
|
|
11217
11262
|
module.exports = ReactFeatureFlags;
|
|
11218
|
-
},{}],
|
|
11263
|
+
},{}],72:[function(_dereq_,module,exports){
|
|
11219
11264
|
/**
|
|
11220
11265
|
* Copyright 2015-present, Facebook, Inc.
|
|
11221
11266
|
* All rights reserved.
|
|
@@ -11230,7 +11275,7 @@ module.exports = ReactFeatureFlags;
|
|
|
11230
11275
|
'use strict';
|
|
11231
11276
|
|
|
11232
11277
|
var ReactChildren = _dereq_(32);
|
|
11233
|
-
var ReactElement = _dereq_(
|
|
11278
|
+
var ReactElement = _dereq_(65);
|
|
11234
11279
|
|
|
11235
11280
|
var emptyFunction = _dereq_(165);
|
|
11236
11281
|
var invariant = _dereq_(173);
|
|
@@ -11249,8 +11294,11 @@ var numericPropertyRegex = /^\d+$/;
|
|
|
11249
11294
|
var warnedAboutNumeric = false;
|
|
11250
11295
|
|
|
11251
11296
|
var ReactFragment = {
|
|
11252
|
-
|
|
11253
|
-
|
|
11297
|
+
/**
|
|
11298
|
+
* Wrap a keyed object in an opaque proxy that warns you if you access any
|
|
11299
|
+
* of its properties.
|
|
11300
|
+
* See https://facebook.github.io/react/docs/create-fragment.html
|
|
11301
|
+
*/
|
|
11254
11302
|
create: function (object) {
|
|
11255
11303
|
if (typeof object !== 'object' || !object || Array.isArray(object)) {
|
|
11256
11304
|
"development" !== 'production' ? warning(false, 'React.addons.createFragment only accepts a single object. Got: %s', object) : void 0;
|
|
@@ -11280,7 +11328,7 @@ var ReactFragment = {
|
|
|
11280
11328
|
};
|
|
11281
11329
|
|
|
11282
11330
|
module.exports = ReactFragment;
|
|
11283
|
-
},{"165":165,"173":173,"183":183,"32":32,"
|
|
11331
|
+
},{"165":165,"173":173,"183":183,"32":32,"65":65}],73:[function(_dereq_,module,exports){
|
|
11284
11332
|
/**
|
|
11285
11333
|
* Copyright 2013-present, Facebook, Inc.
|
|
11286
11334
|
* All rights reserved.
|
|
@@ -11299,10 +11347,9 @@ var EventPluginHub = _dereq_(17);
|
|
|
11299
11347
|
var EventPluginUtils = _dereq_(19);
|
|
11300
11348
|
var ReactComponentEnvironment = _dereq_(36);
|
|
11301
11349
|
var ReactClass = _dereq_(33);
|
|
11302
|
-
var ReactEmptyComponent = _dereq_(
|
|
11350
|
+
var ReactEmptyComponent = _dereq_(67);
|
|
11303
11351
|
var ReactBrowserEventEmitter = _dereq_(28);
|
|
11304
|
-
var ReactNativeComponent = _dereq_(
|
|
11305
|
-
var ReactPerf = _dereq_(88);
|
|
11352
|
+
var ReactNativeComponent = _dereq_(83);
|
|
11306
11353
|
var ReactUpdates = _dereq_(104);
|
|
11307
11354
|
|
|
11308
11355
|
var ReactInjection = {
|
|
@@ -11314,12 +11361,11 @@ var ReactInjection = {
|
|
|
11314
11361
|
EventPluginUtils: EventPluginUtils.injection,
|
|
11315
11362
|
EventEmitter: ReactBrowserEventEmitter.injection,
|
|
11316
11363
|
NativeComponent: ReactNativeComponent.injection,
|
|
11317
|
-
Perf: ReactPerf.injection,
|
|
11318
11364
|
Updates: ReactUpdates.injection
|
|
11319
11365
|
};
|
|
11320
11366
|
|
|
11321
11367
|
module.exports = ReactInjection;
|
|
11322
|
-
},{"10":10,"104":104,"17":17,"19":19,"28":28,"33":33,"36":36,"
|
|
11368
|
+
},{"10":10,"104":104,"17":17,"19":19,"28":28,"33":33,"36":36,"67":67,"83":83}],74:[function(_dereq_,module,exports){
|
|
11323
11369
|
/**
|
|
11324
11370
|
* Copyright 2013-present, Facebook, Inc.
|
|
11325
11371
|
* All rights reserved.
|
|
@@ -11333,7 +11379,7 @@ module.exports = ReactInjection;
|
|
|
11333
11379
|
|
|
11334
11380
|
'use strict';
|
|
11335
11381
|
|
|
11336
|
-
var ReactDOMSelection = _dereq_(
|
|
11382
|
+
var ReactDOMSelection = _dereq_(56);
|
|
11337
11383
|
|
|
11338
11384
|
var containsNode = _dereq_(162);
|
|
11339
11385
|
var focusNode = _dereq_(167);
|
|
@@ -11444,7 +11490,7 @@ var ReactInputSelection = {
|
|
|
11444
11490
|
};
|
|
11445
11491
|
|
|
11446
11492
|
module.exports = ReactInputSelection;
|
|
11447
|
-
},{"162":162,"167":167,"168":168,"
|
|
11493
|
+
},{"162":162,"167":167,"168":168,"56":56}],75:[function(_dereq_,module,exports){
|
|
11448
11494
|
/**
|
|
11449
11495
|
* Copyright 2013-present, Facebook, Inc.
|
|
11450
11496
|
* All rights reserved.
|
|
@@ -11493,7 +11539,7 @@ var ReactInstanceMap = {
|
|
|
11493
11539
|
};
|
|
11494
11540
|
|
|
11495
11541
|
module.exports = ReactInstanceMap;
|
|
11496
|
-
},{}],
|
|
11542
|
+
},{}],76:[function(_dereq_,module,exports){
|
|
11497
11543
|
/**
|
|
11498
11544
|
* Copyright 2016-present, Facebook, Inc.
|
|
11499
11545
|
* All rights reserved.
|
|
@@ -11507,10 +11553,10 @@ module.exports = ReactInstanceMap;
|
|
|
11507
11553
|
|
|
11508
11554
|
'use strict';
|
|
11509
11555
|
|
|
11510
|
-
var ReactDebugTool = _dereq_(
|
|
11556
|
+
var ReactDebugTool = _dereq_(62);
|
|
11511
11557
|
|
|
11512
11558
|
module.exports = { debugTool: ReactDebugTool };
|
|
11513
|
-
},{"
|
|
11559
|
+
},{"62":62}],77:[function(_dereq_,module,exports){
|
|
11514
11560
|
/**
|
|
11515
11561
|
* Copyright 2016-present, Facebook, Inc.
|
|
11516
11562
|
* All rights reserved.
|
|
@@ -11547,7 +11593,7 @@ var ReactInvalidSetStateWarningDevTool = {
|
|
|
11547
11593
|
};
|
|
11548
11594
|
|
|
11549
11595
|
module.exports = ReactInvalidSetStateWarningDevTool;
|
|
11550
|
-
},{"183":183}],
|
|
11596
|
+
},{"183":183}],78:[function(_dereq_,module,exports){
|
|
11551
11597
|
/**
|
|
11552
11598
|
* Copyright 2013-present, Facebook, Inc.
|
|
11553
11599
|
* All rights reserved.
|
|
@@ -11587,6 +11633,9 @@ module.exports = ReactInvalidSetStateWarningDevTool;
|
|
|
11587
11633
|
var React = _dereq_(27);
|
|
11588
11634
|
|
|
11589
11635
|
/**
|
|
11636
|
+
* Deprecated: An an easy way to express two-way binding with React.
|
|
11637
|
+
* See https://facebook.github.io/react/docs/two-way-binding-helpers.html
|
|
11638
|
+
*
|
|
11590
11639
|
* @param {*} value current value of the link
|
|
11591
11640
|
* @param {function} requestChange callback to request a change
|
|
11592
11641
|
*/
|
|
@@ -11616,7 +11665,7 @@ ReactLink.PropTypes = {
|
|
|
11616
11665
|
};
|
|
11617
11666
|
|
|
11618
11667
|
module.exports = ReactLink;
|
|
11619
|
-
},{"27":27}],
|
|
11668
|
+
},{"27":27}],79:[function(_dereq_,module,exports){
|
|
11620
11669
|
/**
|
|
11621
11670
|
* Copyright 2013-present, Facebook, Inc.
|
|
11622
11671
|
* All rights reserved.
|
|
@@ -11667,7 +11716,7 @@ var ReactMarkupChecksum = {
|
|
|
11667
11716
|
};
|
|
11668
11717
|
|
|
11669
11718
|
module.exports = ReactMarkupChecksum;
|
|
11670
|
-
},{"127":127}],
|
|
11719
|
+
},{"127":127}],80:[function(_dereq_,module,exports){
|
|
11671
11720
|
/**
|
|
11672
11721
|
* Copyright 2013-present, Facebook, Inc.
|
|
11673
11722
|
* All rights reserved.
|
|
@@ -11684,15 +11733,14 @@ module.exports = ReactMarkupChecksum;
|
|
|
11684
11733
|
var DOMLazyTree = _dereq_(8);
|
|
11685
11734
|
var DOMProperty = _dereq_(10);
|
|
11686
11735
|
var ReactBrowserEventEmitter = _dereq_(28);
|
|
11687
|
-
var ReactCurrentOwner = _dereq_(
|
|
11688
|
-
var ReactDOMComponentTree = _dereq_(
|
|
11689
|
-
var ReactDOMContainerInfo = _dereq_(
|
|
11690
|
-
var ReactDOMFeatureFlags = _dereq_(
|
|
11691
|
-
var ReactElement = _dereq_(
|
|
11692
|
-
var ReactFeatureFlags = _dereq_(
|
|
11693
|
-
var ReactInstrumentation = _dereq_(
|
|
11694
|
-
var ReactMarkupChecksum = _dereq_(
|
|
11695
|
-
var ReactPerf = _dereq_(88);
|
|
11736
|
+
var ReactCurrentOwner = _dereq_(40);
|
|
11737
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
11738
|
+
var ReactDOMContainerInfo = _dereq_(46);
|
|
11739
|
+
var ReactDOMFeatureFlags = _dereq_(50);
|
|
11740
|
+
var ReactElement = _dereq_(65);
|
|
11741
|
+
var ReactFeatureFlags = _dereq_(71);
|
|
11742
|
+
var ReactInstrumentation = _dereq_(76);
|
|
11743
|
+
var ReactMarkupChecksum = _dereq_(79);
|
|
11696
11744
|
var ReactReconciler = _dereq_(93);
|
|
11697
11745
|
var ReactUpdateQueue = _dereq_(103);
|
|
11698
11746
|
var ReactUpdates = _dereq_(104);
|
|
@@ -11930,6 +11978,10 @@ var ReactMount = {
|
|
|
11930
11978
|
* @return {ReactComponent} nextComponent
|
|
11931
11979
|
*/
|
|
11932
11980
|
_renderNewRootComponent: function (nextElement, container, shouldReuseMarkup, context) {
|
|
11981
|
+
if ("development" !== 'production') {
|
|
11982
|
+
ReactInstrumentation.debugTool.onBeginFlush();
|
|
11983
|
+
}
|
|
11984
|
+
|
|
11933
11985
|
// Various parts of our code (such as ReactCompositeComponent's
|
|
11934
11986
|
// _renderValidatedComponent) assume that calls to render aren't nested;
|
|
11935
11987
|
// verify that that's the case.
|
|
@@ -11940,6 +11992,12 @@ var ReactMount = {
|
|
|
11940
11992
|
ReactBrowserEventEmitter.ensureScrollValueMonitoring();
|
|
11941
11993
|
var componentInstance = instantiateReactComponent(nextElement);
|
|
11942
11994
|
|
|
11995
|
+
if ("development" !== 'production') {
|
|
11996
|
+
// Mute future events from the top level wrapper.
|
|
11997
|
+
// It is an implementation detail that devtools should not know about.
|
|
11998
|
+
componentInstance._debugID = 0;
|
|
11999
|
+
}
|
|
12000
|
+
|
|
11943
12001
|
// The initial render is synchronous but any updates that happen during
|
|
11944
12002
|
// rendering, in componentWillMount or componentDidMount, will be batched
|
|
11945
12003
|
// according to the current batching strategy.
|
|
@@ -11950,7 +12008,9 @@ var ReactMount = {
|
|
|
11950
12008
|
instancesByReactRootID[wrapperID] = componentInstance;
|
|
11951
12009
|
|
|
11952
12010
|
if ("development" !== 'production') {
|
|
11953
|
-
|
|
12011
|
+
// The instance here is TopLevelWrapper so we report mount for its child.
|
|
12012
|
+
ReactInstrumentation.debugTool.onMountRootComponent(componentInstance._renderedComponent._debugID);
|
|
12013
|
+
ReactInstrumentation.debugTool.onEndFlush();
|
|
11954
12014
|
}
|
|
11955
12015
|
|
|
11956
12016
|
return componentInstance;
|
|
@@ -12030,6 +12090,7 @@ var ReactMount = {
|
|
|
12030
12090
|
|
|
12031
12091
|
/**
|
|
12032
12092
|
* Renders a React component into the DOM in the supplied `container`.
|
|
12093
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#reactdom.render
|
|
12033
12094
|
*
|
|
12034
12095
|
* If the React component was previously rendered into `container`, this will
|
|
12035
12096
|
* perform an update on it and only mutate the DOM as necessary to reflect the
|
|
@@ -12046,6 +12107,7 @@ var ReactMount = {
|
|
|
12046
12107
|
|
|
12047
12108
|
/**
|
|
12048
12109
|
* Unmounts and destroys the React component rendered in the `container`.
|
|
12110
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#reactdom.unmountcomponentatnode
|
|
12049
12111
|
*
|
|
12050
12112
|
* @param {DOMElement} container DOM element containing a React component.
|
|
12051
12113
|
* @return {boolean} True if a component was found in and unmounted from
|
|
@@ -12137,16 +12199,18 @@ var ReactMount = {
|
|
|
12137
12199
|
setInnerHTML(container, markup);
|
|
12138
12200
|
ReactDOMComponentTree.precacheNode(instance, container.firstChild);
|
|
12139
12201
|
}
|
|
12202
|
+
|
|
12203
|
+
if ("development" !== 'production') {
|
|
12204
|
+
var nativeNode = ReactDOMComponentTree.getInstanceFromNode(container.firstChild);
|
|
12205
|
+
if (nativeNode._debugID !== 0) {
|
|
12206
|
+
ReactInstrumentation.debugTool.onNativeOperation(nativeNode._debugID, 'mount', markup.toString());
|
|
12207
|
+
}
|
|
12208
|
+
}
|
|
12140
12209
|
}
|
|
12141
12210
|
};
|
|
12142
12211
|
|
|
12143
|
-
ReactPerf.measureMethods(ReactMount, 'ReactMount', {
|
|
12144
|
-
_renderNewRootComponent: '_renderNewRootComponent',
|
|
12145
|
-
_mountImageIntoNode: '_mountImageIntoNode'
|
|
12146
|
-
});
|
|
12147
|
-
|
|
12148
12212
|
module.exports = ReactMount;
|
|
12149
|
-
},{"10":10,"103":103,"104":104,"144":144,"150":150,"153":153,"166":166,"173":173,"183":183,"28":28,"
|
|
12213
|
+
},{"10":10,"103":103,"104":104,"144":144,"150":150,"153":153,"166":166,"173":173,"183":183,"28":28,"40":40,"45":45,"46":46,"50":50,"65":65,"71":71,"76":76,"79":79,"8":8,"93":93}],81:[function(_dereq_,module,exports){
|
|
12150
12214
|
/**
|
|
12151
12215
|
* Copyright 2013-present, Facebook, Inc.
|
|
12152
12216
|
* All rights reserved.
|
|
@@ -12161,12 +12225,14 @@ module.exports = ReactMount;
|
|
|
12161
12225
|
'use strict';
|
|
12162
12226
|
|
|
12163
12227
|
var ReactComponentEnvironment = _dereq_(36);
|
|
12164
|
-
var
|
|
12228
|
+
var ReactInstrumentation = _dereq_(76);
|
|
12229
|
+
var ReactMultiChildUpdateTypes = _dereq_(82);
|
|
12165
12230
|
|
|
12166
|
-
var ReactCurrentOwner = _dereq_(
|
|
12231
|
+
var ReactCurrentOwner = _dereq_(40);
|
|
12167
12232
|
var ReactReconciler = _dereq_(93);
|
|
12168
12233
|
var ReactChildReconciler = _dereq_(31);
|
|
12169
12234
|
|
|
12235
|
+
var emptyFunction = _dereq_(165);
|
|
12170
12236
|
var flattenChildren = _dereq_(133);
|
|
12171
12237
|
var invariant = _dereq_(173);
|
|
12172
12238
|
|
|
@@ -12283,6 +12349,15 @@ function processQueue(inst, updateQueue) {
|
|
|
12283
12349
|
ReactComponentEnvironment.processChildrenUpdates(inst, updateQueue);
|
|
12284
12350
|
}
|
|
12285
12351
|
|
|
12352
|
+
var setChildrenForInstrumentation = emptyFunction;
|
|
12353
|
+
if ("development" !== 'production') {
|
|
12354
|
+
setChildrenForInstrumentation = function (children) {
|
|
12355
|
+
ReactInstrumentation.debugTool.onSetChildren(this._debugID, children ? Object.keys(children).map(function (key) {
|
|
12356
|
+
return children[key]._debugID;
|
|
12357
|
+
}) : []);
|
|
12358
|
+
};
|
|
12359
|
+
}
|
|
12360
|
+
|
|
12286
12361
|
/**
|
|
12287
12362
|
* ReactMultiChild are capable of reconciling multiple children.
|
|
12288
12363
|
*
|
|
@@ -12344,6 +12419,7 @@ var ReactMultiChild = {
|
|
|
12344
12419
|
mountChildren: function (nestedChildren, transaction, context) {
|
|
12345
12420
|
var children = this._reconcilerInstantiateChildren(nestedChildren, transaction, context);
|
|
12346
12421
|
this._renderedChildren = children;
|
|
12422
|
+
|
|
12347
12423
|
var mountImages = [];
|
|
12348
12424
|
var index = 0;
|
|
12349
12425
|
for (var name in children) {
|
|
@@ -12354,6 +12430,11 @@ var ReactMultiChild = {
|
|
|
12354
12430
|
mountImages.push(mountImage);
|
|
12355
12431
|
}
|
|
12356
12432
|
}
|
|
12433
|
+
|
|
12434
|
+
if ("development" !== 'production') {
|
|
12435
|
+
setChildrenForInstrumentation.call(this, children);
|
|
12436
|
+
}
|
|
12437
|
+
|
|
12357
12438
|
return mountImages;
|
|
12358
12439
|
},
|
|
12359
12440
|
|
|
@@ -12460,6 +12541,10 @@ var ReactMultiChild = {
|
|
|
12460
12541
|
processQueue(this, updates);
|
|
12461
12542
|
}
|
|
12462
12543
|
this._renderedChildren = nextChildren;
|
|
12544
|
+
|
|
12545
|
+
if ("development" !== 'production') {
|
|
12546
|
+
setChildrenForInstrumentation.call(this, nextChildren);
|
|
12547
|
+
}
|
|
12463
12548
|
},
|
|
12464
12549
|
|
|
12465
12550
|
/**
|
|
@@ -12549,7 +12634,7 @@ var ReactMultiChild = {
|
|
|
12549
12634
|
};
|
|
12550
12635
|
|
|
12551
12636
|
module.exports = ReactMultiChild;
|
|
12552
|
-
},{"133":133,"173":173,"31":31,"36":36,"
|
|
12637
|
+
},{"133":133,"165":165,"173":173,"31":31,"36":36,"40":40,"76":76,"82":82,"93":93}],82:[function(_dereq_,module,exports){
|
|
12553
12638
|
/**
|
|
12554
12639
|
* Copyright 2013-present, Facebook, Inc.
|
|
12555
12640
|
* All rights reserved.
|
|
@@ -12582,7 +12667,7 @@ var ReactMultiChildUpdateTypes = keyMirror({
|
|
|
12582
12667
|
});
|
|
12583
12668
|
|
|
12584
12669
|
module.exports = ReactMultiChildUpdateTypes;
|
|
12585
|
-
},{"176":176}],
|
|
12670
|
+
},{"176":176}],83:[function(_dereq_,module,exports){
|
|
12586
12671
|
/**
|
|
12587
12672
|
* Copyright 2014-present, Facebook, Inc.
|
|
12588
12673
|
* All rights reserved.
|
|
@@ -12678,7 +12763,45 @@ var ReactNativeComponent = {
|
|
|
12678
12763
|
};
|
|
12679
12764
|
|
|
12680
12765
|
module.exports = ReactNativeComponent;
|
|
12681
|
-
},{"173":173,"184":184}],
|
|
12766
|
+
},{"173":173,"184":184}],84:[function(_dereq_,module,exports){
|
|
12767
|
+
/**
|
|
12768
|
+
* Copyright 2016-present, Facebook, Inc.
|
|
12769
|
+
* All rights reserved.
|
|
12770
|
+
*
|
|
12771
|
+
* This source code is licensed under the BSD-style license found in the
|
|
12772
|
+
* LICENSE file in the root directory of this source tree. An additional grant
|
|
12773
|
+
* of patent rights can be found in the PATENTS file in the same directory.
|
|
12774
|
+
*
|
|
12775
|
+
* @providesModule ReactNativeOperationHistoryDevtool
|
|
12776
|
+
*/
|
|
12777
|
+
|
|
12778
|
+
'use strict';
|
|
12779
|
+
|
|
12780
|
+
var history = [];
|
|
12781
|
+
|
|
12782
|
+
var ReactNativeOperationHistoryDevtool = {
|
|
12783
|
+
onNativeOperation: function (debugID, type, payload) {
|
|
12784
|
+
history.push({
|
|
12785
|
+
instanceID: debugID,
|
|
12786
|
+
type: type,
|
|
12787
|
+
payload: payload
|
|
12788
|
+
});
|
|
12789
|
+
},
|
|
12790
|
+
clearHistory: function () {
|
|
12791
|
+
if (ReactNativeOperationHistoryDevtool._preventClearing) {
|
|
12792
|
+
// Should only be used for tests.
|
|
12793
|
+
return;
|
|
12794
|
+
}
|
|
12795
|
+
|
|
12796
|
+
history = [];
|
|
12797
|
+
},
|
|
12798
|
+
getHistory: function () {
|
|
12799
|
+
return history;
|
|
12800
|
+
}
|
|
12801
|
+
};
|
|
12802
|
+
|
|
12803
|
+
module.exports = ReactNativeOperationHistoryDevtool;
|
|
12804
|
+
},{}],85:[function(_dereq_,module,exports){
|
|
12682
12805
|
/**
|
|
12683
12806
|
* Copyright 2013-present, Facebook, Inc.
|
|
12684
12807
|
* All rights reserved.
|
|
@@ -12692,7 +12815,7 @@ module.exports = ReactNativeComponent;
|
|
|
12692
12815
|
|
|
12693
12816
|
'use strict';
|
|
12694
12817
|
|
|
12695
|
-
var ReactElement = _dereq_(
|
|
12818
|
+
var ReactElement = _dereq_(65);
|
|
12696
12819
|
|
|
12697
12820
|
var invariant = _dereq_(173);
|
|
12698
12821
|
|
|
@@ -12716,7 +12839,7 @@ var ReactNodeTypes = {
|
|
|
12716
12839
|
};
|
|
12717
12840
|
|
|
12718
12841
|
module.exports = ReactNodeTypes;
|
|
12719
|
-
},{"173":173,"
|
|
12842
|
+
},{"173":173,"65":65}],86:[function(_dereq_,module,exports){
|
|
12720
12843
|
/**
|
|
12721
12844
|
* Copyright 2015-present, Facebook, Inc.
|
|
12722
12845
|
* All rights reserved.
|
|
@@ -12907,7 +13030,7 @@ var ReactOwner = {
|
|
|
12907
13030
|
module.exports = ReactOwner;
|
|
12908
13031
|
},{"173":173}],88:[function(_dereq_,module,exports){
|
|
12909
13032
|
/**
|
|
12910
|
-
* Copyright
|
|
13033
|
+
* Copyright 2016-present, Facebook, Inc.
|
|
12911
13034
|
* All rights reserved.
|
|
12912
13035
|
*
|
|
12913
13036
|
* This source code is licensed under the BSD-style license found in the
|
|
@@ -12919,90 +13042,412 @@ module.exports = ReactOwner;
|
|
|
12919
13042
|
|
|
12920
13043
|
'use strict';
|
|
12921
13044
|
|
|
12922
|
-
|
|
12923
|
-
* ReactPerf is a general AOP system designed to measure performance. This
|
|
12924
|
-
* module only has the hooks: see ReactDefaultPerf for the analysis tool.
|
|
12925
|
-
*/
|
|
13045
|
+
var _assign = _dereq_(184);
|
|
12926
13046
|
|
|
12927
|
-
var
|
|
12928
|
-
/**
|
|
12929
|
-
* Boolean to enable/disable measurement. Set to false by default to prevent
|
|
12930
|
-
* accidental logging and perf loss.
|
|
12931
|
-
*/
|
|
12932
|
-
enableMeasure: false,
|
|
13047
|
+
var _extends = _assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
|
12933
13048
|
|
|
12934
|
-
|
|
12935
|
-
|
|
12936
|
-
* anything, but we'll override this if we inject a measure function.
|
|
12937
|
-
*/
|
|
12938
|
-
storedMeasure: _noMeasure,
|
|
13049
|
+
var ReactDebugTool = _dereq_(62);
|
|
13050
|
+
var warning = _dereq_(183);
|
|
12939
13051
|
|
|
12940
|
-
|
|
12941
|
-
|
|
12942
|
-
|
|
12943
|
-
|
|
12944
|
-
|
|
12945
|
-
|
|
12946
|
-
|
|
12947
|
-
|
|
12948
|
-
|
|
12949
|
-
|
|
12950
|
-
|
|
12951
|
-
|
|
12952
|
-
|
|
13052
|
+
function roundFloat(val) {
|
|
13053
|
+
var base = arguments.length <= 1 || arguments[1] === undefined ? 2 : arguments[1];
|
|
13054
|
+
|
|
13055
|
+
var n = Math.pow(10, base);
|
|
13056
|
+
return Math.floor(val * n) / n;
|
|
13057
|
+
}
|
|
13058
|
+
|
|
13059
|
+
function getFlushHistory() {
|
|
13060
|
+
return ReactDebugTool.getFlushHistory();
|
|
13061
|
+
}
|
|
13062
|
+
|
|
13063
|
+
function getExclusive() {
|
|
13064
|
+
var flushHistory = arguments.length <= 0 || arguments[0] === undefined ? getFlushHistory() : arguments[0];
|
|
13065
|
+
|
|
13066
|
+
var aggregatedStats = {};
|
|
13067
|
+
var affectedIDs = {};
|
|
13068
|
+
|
|
13069
|
+
function updateAggregatedStats(treeSnapshot, instanceID, timerType, applyUpdate) {
|
|
13070
|
+
var displayName = treeSnapshot[instanceID].displayName;
|
|
13071
|
+
|
|
13072
|
+
var key = displayName;
|
|
13073
|
+
var stats = aggregatedStats[key];
|
|
13074
|
+
if (!stats) {
|
|
13075
|
+
affectedIDs[key] = {};
|
|
13076
|
+
stats = aggregatedStats[key] = {
|
|
13077
|
+
key: key,
|
|
13078
|
+
instanceCount: 0,
|
|
13079
|
+
counts: {},
|
|
13080
|
+
durations: {},
|
|
13081
|
+
totalDuration: 0
|
|
13082
|
+
};
|
|
12953
13083
|
}
|
|
12954
|
-
|
|
13084
|
+
if (!stats.durations[timerType]) {
|
|
13085
|
+
stats.durations[timerType] = 0;
|
|
13086
|
+
}
|
|
13087
|
+
if (!stats.counts[timerType]) {
|
|
13088
|
+
stats.counts[timerType] = 0;
|
|
13089
|
+
}
|
|
13090
|
+
affectedIDs[key][instanceID] = true;
|
|
13091
|
+
applyUpdate(stats);
|
|
13092
|
+
}
|
|
12955
13093
|
|
|
12956
|
-
|
|
12957
|
-
|
|
12958
|
-
|
|
12959
|
-
|
|
12960
|
-
|
|
12961
|
-
|
|
12962
|
-
|
|
12963
|
-
|
|
12964
|
-
|
|
12965
|
-
|
|
12966
|
-
|
|
12967
|
-
|
|
12968
|
-
|
|
12969
|
-
|
|
12970
|
-
|
|
12971
|
-
|
|
12972
|
-
|
|
12973
|
-
|
|
12974
|
-
|
|
13094
|
+
flushHistory.forEach(function (flush) {
|
|
13095
|
+
var measurements = flush.measurements;
|
|
13096
|
+
var treeSnapshot = flush.treeSnapshot;
|
|
13097
|
+
|
|
13098
|
+
measurements.forEach(function (measurement) {
|
|
13099
|
+
var duration = measurement.duration;
|
|
13100
|
+
var instanceID = measurement.instanceID;
|
|
13101
|
+
var timerType = measurement.timerType;
|
|
13102
|
+
|
|
13103
|
+
updateAggregatedStats(treeSnapshot, instanceID, timerType, function (stats) {
|
|
13104
|
+
stats.totalDuration += duration;
|
|
13105
|
+
stats.durations[timerType] += duration;
|
|
13106
|
+
stats.counts[timerType]++;
|
|
13107
|
+
});
|
|
13108
|
+
});
|
|
13109
|
+
});
|
|
13110
|
+
|
|
13111
|
+
return Object.keys(aggregatedStats).map(function (key) {
|
|
13112
|
+
return _extends({}, aggregatedStats[key], {
|
|
13113
|
+
instanceCount: Object.keys(affectedIDs[key]).length
|
|
13114
|
+
});
|
|
13115
|
+
}).sort(function (a, b) {
|
|
13116
|
+
return b.totalDuration - a.totalDuration;
|
|
13117
|
+
});
|
|
13118
|
+
}
|
|
13119
|
+
|
|
13120
|
+
function getInclusive() {
|
|
13121
|
+
var flushHistory = arguments.length <= 0 || arguments[0] === undefined ? getFlushHistory() : arguments[0];
|
|
13122
|
+
|
|
13123
|
+
var aggregatedStats = {};
|
|
13124
|
+
var affectedIDs = {};
|
|
13125
|
+
|
|
13126
|
+
function updateAggregatedStats(treeSnapshot, instanceID, applyUpdate) {
|
|
13127
|
+
var _treeSnapshot$instanc = treeSnapshot[instanceID];
|
|
13128
|
+
var displayName = _treeSnapshot$instanc.displayName;
|
|
13129
|
+
var ownerID = _treeSnapshot$instanc.ownerID;
|
|
13130
|
+
|
|
13131
|
+
var owner = treeSnapshot[ownerID];
|
|
13132
|
+
var key = (owner ? owner.displayName + ' > ' : '') + displayName;
|
|
13133
|
+
var stats = aggregatedStats[key];
|
|
13134
|
+
if (!stats) {
|
|
13135
|
+
affectedIDs[key] = {};
|
|
13136
|
+
stats = aggregatedStats[key] = {
|
|
13137
|
+
key: key,
|
|
13138
|
+
instanceCount: 0,
|
|
13139
|
+
inclusiveRenderDuration: 0,
|
|
13140
|
+
renderCount: 0
|
|
12975
13141
|
};
|
|
12976
|
-
wrapper.displayName = objName + '_' + fnName;
|
|
12977
|
-
return wrapper;
|
|
12978
13142
|
}
|
|
12979
|
-
|
|
12980
|
-
|
|
13143
|
+
affectedIDs[key][instanceID] = true;
|
|
13144
|
+
applyUpdate(stats);
|
|
13145
|
+
}
|
|
12981
13146
|
|
|
12982
|
-
|
|
12983
|
-
|
|
12984
|
-
|
|
12985
|
-
|
|
12986
|
-
|
|
12987
|
-
|
|
13147
|
+
var isCompositeByID = {};
|
|
13148
|
+
flushHistory.forEach(function (flush) {
|
|
13149
|
+
var measurements = flush.measurements;
|
|
13150
|
+
|
|
13151
|
+
measurements.forEach(function (measurement) {
|
|
13152
|
+
var instanceID = measurement.instanceID;
|
|
13153
|
+
var timerType = measurement.timerType;
|
|
13154
|
+
|
|
13155
|
+
if (timerType !== 'render') {
|
|
13156
|
+
return;
|
|
13157
|
+
}
|
|
13158
|
+
isCompositeByID[instanceID] = true;
|
|
13159
|
+
});
|
|
13160
|
+
});
|
|
13161
|
+
|
|
13162
|
+
flushHistory.forEach(function (flush) {
|
|
13163
|
+
var measurements = flush.measurements;
|
|
13164
|
+
var treeSnapshot = flush.treeSnapshot;
|
|
13165
|
+
|
|
13166
|
+
measurements.forEach(function (measurement) {
|
|
13167
|
+
var duration = measurement.duration;
|
|
13168
|
+
var instanceID = measurement.instanceID;
|
|
13169
|
+
var timerType = measurement.timerType;
|
|
13170
|
+
|
|
13171
|
+
if (timerType !== 'render') {
|
|
13172
|
+
return;
|
|
13173
|
+
}
|
|
13174
|
+
updateAggregatedStats(treeSnapshot, instanceID, function (stats) {
|
|
13175
|
+
stats.renderCount++;
|
|
13176
|
+
});
|
|
13177
|
+
var nextParentID = instanceID;
|
|
13178
|
+
while (nextParentID) {
|
|
13179
|
+
// As we traverse parents, only count inclusive time towards composites.
|
|
13180
|
+
// We know something is a composite if its render() was called.
|
|
13181
|
+
if (isCompositeByID[nextParentID]) {
|
|
13182
|
+
updateAggregatedStats(treeSnapshot, nextParentID, function (stats) {
|
|
13183
|
+
stats.inclusiveRenderDuration += duration;
|
|
13184
|
+
});
|
|
13185
|
+
}
|
|
13186
|
+
nextParentID = treeSnapshot[nextParentID].parentID;
|
|
13187
|
+
}
|
|
13188
|
+
});
|
|
13189
|
+
});
|
|
13190
|
+
|
|
13191
|
+
return Object.keys(aggregatedStats).map(function (key) {
|
|
13192
|
+
return _extends({}, aggregatedStats[key], {
|
|
13193
|
+
instanceCount: Object.keys(affectedIDs[key]).length
|
|
13194
|
+
});
|
|
13195
|
+
}).sort(function (a, b) {
|
|
13196
|
+
return b.inclusiveRenderDuration - a.inclusiveRenderDuration;
|
|
13197
|
+
});
|
|
13198
|
+
}
|
|
13199
|
+
|
|
13200
|
+
function getWasted() {
|
|
13201
|
+
var flushHistory = arguments.length <= 0 || arguments[0] === undefined ? getFlushHistory() : arguments[0];
|
|
13202
|
+
|
|
13203
|
+
var aggregatedStats = {};
|
|
13204
|
+
var affectedIDs = {};
|
|
13205
|
+
|
|
13206
|
+
function updateAggregatedStats(treeSnapshot, instanceID, applyUpdate) {
|
|
13207
|
+
var _treeSnapshot$instanc2 = treeSnapshot[instanceID];
|
|
13208
|
+
var displayName = _treeSnapshot$instanc2.displayName;
|
|
13209
|
+
var ownerID = _treeSnapshot$instanc2.ownerID;
|
|
13210
|
+
|
|
13211
|
+
var owner = treeSnapshot[ownerID];
|
|
13212
|
+
var key = (owner ? owner.displayName + ' > ' : '') + displayName;
|
|
13213
|
+
var stats = aggregatedStats[key];
|
|
13214
|
+
if (!stats) {
|
|
13215
|
+
affectedIDs[key] = {};
|
|
13216
|
+
stats = aggregatedStats[key] = {
|
|
13217
|
+
key: key,
|
|
13218
|
+
instanceCount: 0,
|
|
13219
|
+
inclusiveRenderDuration: 0,
|
|
13220
|
+
renderCount: 0
|
|
13221
|
+
};
|
|
12988
13222
|
}
|
|
13223
|
+
affectedIDs[key][instanceID] = true;
|
|
13224
|
+
applyUpdate(stats);
|
|
12989
13225
|
}
|
|
12990
|
-
};
|
|
12991
13226
|
|
|
12992
|
-
|
|
12993
|
-
|
|
12994
|
-
|
|
12995
|
-
|
|
12996
|
-
|
|
12997
|
-
|
|
12998
|
-
|
|
12999
|
-
|
|
13000
|
-
|
|
13001
|
-
|
|
13227
|
+
flushHistory.forEach(function (flush) {
|
|
13228
|
+
var measurements = flush.measurements;
|
|
13229
|
+
var treeSnapshot = flush.treeSnapshot;
|
|
13230
|
+
var operations = flush.operations;
|
|
13231
|
+
|
|
13232
|
+
var isDefinitelyNotWastedByID = {};
|
|
13233
|
+
|
|
13234
|
+
// Find native components associated with an operation in this batch.
|
|
13235
|
+
// Mark all components in their parent tree as definitely not wasted.
|
|
13236
|
+
operations.forEach(function (operation) {
|
|
13237
|
+
var instanceID = operation.instanceID;
|
|
13238
|
+
|
|
13239
|
+
var nextParentID = instanceID;
|
|
13240
|
+
while (nextParentID) {
|
|
13241
|
+
isDefinitelyNotWastedByID[nextParentID] = true;
|
|
13242
|
+
nextParentID = treeSnapshot[nextParentID].parentID;
|
|
13243
|
+
}
|
|
13244
|
+
});
|
|
13245
|
+
|
|
13246
|
+
// Find composite components that rendered in this batch.
|
|
13247
|
+
// These are potential candidates for being wasted renders.
|
|
13248
|
+
var renderedCompositeIDs = {};
|
|
13249
|
+
measurements.forEach(function (measurement) {
|
|
13250
|
+
var instanceID = measurement.instanceID;
|
|
13251
|
+
var timerType = measurement.timerType;
|
|
13252
|
+
|
|
13253
|
+
if (timerType !== 'render') {
|
|
13254
|
+
return;
|
|
13255
|
+
}
|
|
13256
|
+
renderedCompositeIDs[instanceID] = true;
|
|
13257
|
+
});
|
|
13258
|
+
|
|
13259
|
+
measurements.forEach(function (measurement) {
|
|
13260
|
+
var duration = measurement.duration;
|
|
13261
|
+
var instanceID = measurement.instanceID;
|
|
13262
|
+
var timerType = measurement.timerType;
|
|
13263
|
+
|
|
13264
|
+
if (timerType !== 'render') {
|
|
13265
|
+
return;
|
|
13266
|
+
}
|
|
13267
|
+
|
|
13268
|
+
// If there was a DOM update below this component, or it has just been
|
|
13269
|
+
// mounted, its render() is not considered wasted.
|
|
13270
|
+
var updateCount = treeSnapshot[instanceID].updateCount;
|
|
13271
|
+
|
|
13272
|
+
if (isDefinitelyNotWastedByID[instanceID] || updateCount === 0) {
|
|
13273
|
+
return;
|
|
13274
|
+
}
|
|
13275
|
+
|
|
13276
|
+
// We consider this render() wasted.
|
|
13277
|
+
updateAggregatedStats(treeSnapshot, instanceID, function (stats) {
|
|
13278
|
+
stats.renderCount++;
|
|
13279
|
+
});
|
|
13280
|
+
|
|
13281
|
+
var nextParentID = instanceID;
|
|
13282
|
+
while (nextParentID) {
|
|
13283
|
+
// Any parents rendered during this batch are considered wasted
|
|
13284
|
+
// unless we previously marked them as dirty.
|
|
13285
|
+
var isWasted = renderedCompositeIDs[nextParentID] && !isDefinitelyNotWastedByID[nextParentID];
|
|
13286
|
+
if (isWasted) {
|
|
13287
|
+
updateAggregatedStats(treeSnapshot, nextParentID, function (stats) {
|
|
13288
|
+
stats.inclusiveRenderDuration += duration;
|
|
13289
|
+
});
|
|
13290
|
+
}
|
|
13291
|
+
nextParentID = treeSnapshot[nextParentID].parentID;
|
|
13292
|
+
}
|
|
13293
|
+
});
|
|
13294
|
+
});
|
|
13295
|
+
|
|
13296
|
+
return Object.keys(aggregatedStats).map(function (key) {
|
|
13297
|
+
return _extends({}, aggregatedStats[key], {
|
|
13298
|
+
instanceCount: Object.keys(affectedIDs[key]).length
|
|
13299
|
+
});
|
|
13300
|
+
}).sort(function (a, b) {
|
|
13301
|
+
return b.inclusiveRenderDuration - a.inclusiveRenderDuration;
|
|
13302
|
+
});
|
|
13303
|
+
}
|
|
13304
|
+
|
|
13305
|
+
function getOperations() {
|
|
13306
|
+
var flushHistory = arguments.length <= 0 || arguments[0] === undefined ? getFlushHistory() : arguments[0];
|
|
13307
|
+
|
|
13308
|
+
var stats = [];
|
|
13309
|
+
flushHistory.forEach(function (flush, flushIndex) {
|
|
13310
|
+
var operations = flush.operations;
|
|
13311
|
+
var treeSnapshot = flush.treeSnapshot;
|
|
13312
|
+
|
|
13313
|
+
operations.forEach(function (operation) {
|
|
13314
|
+
var instanceID = operation.instanceID;
|
|
13315
|
+
var type = operation.type;
|
|
13316
|
+
var payload = operation.payload;
|
|
13317
|
+
var _treeSnapshot$instanc3 = treeSnapshot[instanceID];
|
|
13318
|
+
var displayName = _treeSnapshot$instanc3.displayName;
|
|
13319
|
+
var ownerID = _treeSnapshot$instanc3.ownerID;
|
|
13320
|
+
|
|
13321
|
+
var owner = treeSnapshot[ownerID];
|
|
13322
|
+
var key = (owner ? owner.displayName + ' > ' : '') + displayName;
|
|
13323
|
+
|
|
13324
|
+
stats.push({
|
|
13325
|
+
flushIndex: flushIndex,
|
|
13326
|
+
instanceID: instanceID,
|
|
13327
|
+
key: key,
|
|
13328
|
+
type: type,
|
|
13329
|
+
ownerID: ownerID,
|
|
13330
|
+
payload: payload
|
|
13331
|
+
});
|
|
13332
|
+
});
|
|
13333
|
+
});
|
|
13334
|
+
return stats;
|
|
13335
|
+
}
|
|
13336
|
+
|
|
13337
|
+
function printExclusive(flushHistory) {
|
|
13338
|
+
var stats = getExclusive(flushHistory);
|
|
13339
|
+
var table = stats.map(function (item) {
|
|
13340
|
+
var key = item.key;
|
|
13341
|
+
var instanceCount = item.instanceCount;
|
|
13342
|
+
var totalDuration = item.totalDuration;
|
|
13343
|
+
|
|
13344
|
+
var renderCount = item.counts.render || 0;
|
|
13345
|
+
var renderDuration = item.durations.render || 0;
|
|
13346
|
+
return {
|
|
13347
|
+
'Component': key,
|
|
13348
|
+
'Total time (ms)': roundFloat(totalDuration),
|
|
13349
|
+
'Instance count': instanceCount,
|
|
13350
|
+
'Total render time (ms)': roundFloat(renderDuration),
|
|
13351
|
+
'Average render time (ms)': renderCount ? roundFloat(renderDuration / renderCount) : undefined,
|
|
13352
|
+
'Render count': renderCount,
|
|
13353
|
+
'Total lifecycle time (ms)': roundFloat(totalDuration - renderDuration)
|
|
13354
|
+
};
|
|
13355
|
+
});
|
|
13356
|
+
console.table(table);
|
|
13357
|
+
}
|
|
13358
|
+
|
|
13359
|
+
function printInclusive(flushHistory) {
|
|
13360
|
+
var stats = getInclusive(flushHistory);
|
|
13361
|
+
var table = stats.map(function (item) {
|
|
13362
|
+
var key = item.key;
|
|
13363
|
+
var instanceCount = item.instanceCount;
|
|
13364
|
+
var inclusiveRenderDuration = item.inclusiveRenderDuration;
|
|
13365
|
+
var renderCount = item.renderCount;
|
|
13366
|
+
|
|
13367
|
+
return {
|
|
13368
|
+
'Owner > Component': key,
|
|
13369
|
+
'Inclusive render time (ms)': roundFloat(inclusiveRenderDuration),
|
|
13370
|
+
'Instance count': instanceCount,
|
|
13371
|
+
'Render count': renderCount
|
|
13372
|
+
};
|
|
13373
|
+
});
|
|
13374
|
+
console.table(table);
|
|
13375
|
+
}
|
|
13376
|
+
|
|
13377
|
+
function printWasted(flushHistory) {
|
|
13378
|
+
var stats = getWasted(flushHistory);
|
|
13379
|
+
var table = stats.map(function (item) {
|
|
13380
|
+
var key = item.key;
|
|
13381
|
+
var instanceCount = item.instanceCount;
|
|
13382
|
+
var inclusiveRenderDuration = item.inclusiveRenderDuration;
|
|
13383
|
+
var renderCount = item.renderCount;
|
|
13384
|
+
|
|
13385
|
+
return {
|
|
13386
|
+
'Owner > Component': key,
|
|
13387
|
+
'Inclusive wasted time (ms)': roundFloat(inclusiveRenderDuration),
|
|
13388
|
+
'Instance count': instanceCount,
|
|
13389
|
+
'Render count': renderCount
|
|
13390
|
+
};
|
|
13391
|
+
});
|
|
13392
|
+
console.table(table);
|
|
13393
|
+
}
|
|
13394
|
+
|
|
13395
|
+
function printOperations(flushHistory) {
|
|
13396
|
+
var stats = getOperations(flushHistory);
|
|
13397
|
+
var table = stats.map(function (stat) {
|
|
13398
|
+
return {
|
|
13399
|
+
'Owner > Node': stat.key,
|
|
13400
|
+
'Operation': stat.type,
|
|
13401
|
+
'Payload': typeof stat.payload === 'object' ? JSON.stringify(stat.payload) : stat.payload,
|
|
13402
|
+
'Flush index': stat.flushIndex,
|
|
13403
|
+
'Owner Component ID': stat.ownerID,
|
|
13404
|
+
'DOM Component ID': stat.instanceID
|
|
13405
|
+
};
|
|
13406
|
+
});
|
|
13407
|
+
console.table(table);
|
|
13408
|
+
}
|
|
13409
|
+
|
|
13410
|
+
var warnedAboutPrintDOM = false;
|
|
13411
|
+
function printDOM(measurements) {
|
|
13412
|
+
"development" !== 'production' ? warning(warnedAboutPrintDOM, '`ReactPerf.printDOM(...)` is deprecated. Use ' + '`ReactPerf.printOperations(...)` instead.') : void 0;
|
|
13413
|
+
warnedAboutPrintDOM = true;
|
|
13414
|
+
return printOperations(measurements);
|
|
13002
13415
|
}
|
|
13003
13416
|
|
|
13004
|
-
|
|
13005
|
-
|
|
13417
|
+
var warnedAboutGetMeasurementsSummaryMap = false;
|
|
13418
|
+
function getMeasurementsSummaryMap(measurements) {
|
|
13419
|
+
"development" !== 'production' ? warning(warnedAboutGetMeasurementsSummaryMap, '`ReactPerf.getMeasurementsSummaryMap(...)` is deprecated. Use ' + '`ReactPerf.getWasted(...)` instead.') : void 0;
|
|
13420
|
+
warnedAboutGetMeasurementsSummaryMap = true;
|
|
13421
|
+
return getWasted(measurements);
|
|
13422
|
+
}
|
|
13423
|
+
|
|
13424
|
+
function start() {
|
|
13425
|
+
ReactDebugTool.beginProfiling();
|
|
13426
|
+
}
|
|
13427
|
+
|
|
13428
|
+
function stop() {
|
|
13429
|
+
ReactDebugTool.endProfiling();
|
|
13430
|
+
}
|
|
13431
|
+
|
|
13432
|
+
var ReactPerfAnalysis = {
|
|
13433
|
+
getLastMeasurements: getFlushHistory,
|
|
13434
|
+
getExclusive: getExclusive,
|
|
13435
|
+
getInclusive: getInclusive,
|
|
13436
|
+
getWasted: getWasted,
|
|
13437
|
+
getOperations: getOperations,
|
|
13438
|
+
printExclusive: printExclusive,
|
|
13439
|
+
printInclusive: printInclusive,
|
|
13440
|
+
printWasted: printWasted,
|
|
13441
|
+
printOperations: printOperations,
|
|
13442
|
+
start: start,
|
|
13443
|
+
stop: stop,
|
|
13444
|
+
// Deprecated:
|
|
13445
|
+
printDOM: printDOM,
|
|
13446
|
+
getMeasurementsSummaryMap: getMeasurementsSummaryMap
|
|
13447
|
+
};
|
|
13448
|
+
|
|
13449
|
+
module.exports = ReactPerfAnalysis;
|
|
13450
|
+
},{"183":183,"184":184,"62":62}],89:[function(_dereq_,module,exports){
|
|
13006
13451
|
/**
|
|
13007
13452
|
* Copyright 2013-present, Facebook, Inc.
|
|
13008
13453
|
* All rights reserved.
|
|
@@ -13064,7 +13509,7 @@ module.exports = ReactPropTypeLocations;
|
|
|
13064
13509
|
|
|
13065
13510
|
'use strict';
|
|
13066
13511
|
|
|
13067
|
-
var ReactElement = _dereq_(
|
|
13512
|
+
var ReactElement = _dereq_(65);
|
|
13068
13513
|
var ReactPropTypeLocationNames = _dereq_(89);
|
|
13069
13514
|
|
|
13070
13515
|
var emptyFunction = _dereq_(165);
|
|
@@ -13431,7 +13876,7 @@ function getClassName(propValue) {
|
|
|
13431
13876
|
}
|
|
13432
13877
|
|
|
13433
13878
|
module.exports = ReactPropTypes;
|
|
13434
|
-
},{"139":139,"165":165,"
|
|
13879
|
+
},{"139":139,"165":165,"65":65,"89":89}],92:[function(_dereq_,module,exports){
|
|
13435
13880
|
/**
|
|
13436
13881
|
* Copyright 2013-present, Facebook, Inc.
|
|
13437
13882
|
* All rights reserved.
|
|
@@ -13450,7 +13895,7 @@ var _assign = _dereq_(184);
|
|
|
13450
13895
|
var CallbackQueue = _dereq_(5);
|
|
13451
13896
|
var PooledClass = _dereq_(26);
|
|
13452
13897
|
var ReactBrowserEventEmitter = _dereq_(28);
|
|
13453
|
-
var ReactInputSelection = _dereq_(
|
|
13898
|
+
var ReactInputSelection = _dereq_(74);
|
|
13454
13899
|
var Transaction = _dereq_(124);
|
|
13455
13900
|
|
|
13456
13901
|
/**
|
|
@@ -13594,7 +14039,7 @@ _assign(ReactReconcileTransaction.prototype, Transaction.Mixin, Mixin);
|
|
|
13594
14039
|
PooledClass.addPoolingTo(ReactReconcileTransaction);
|
|
13595
14040
|
|
|
13596
14041
|
module.exports = ReactReconcileTransaction;
|
|
13597
|
-
},{"124":124,"184":184,"26":26,"28":28,"5":5,"
|
|
14042
|
+
},{"124":124,"184":184,"26":26,"28":28,"5":5,"74":74}],93:[function(_dereq_,module,exports){
|
|
13598
14043
|
/**
|
|
13599
14044
|
* Copyright 2013-present, Facebook, Inc.
|
|
13600
14045
|
* All rights reserved.
|
|
@@ -13609,7 +14054,9 @@ module.exports = ReactReconcileTransaction;
|
|
|
13609
14054
|
'use strict';
|
|
13610
14055
|
|
|
13611
14056
|
var ReactRef = _dereq_(94);
|
|
13612
|
-
var ReactInstrumentation = _dereq_(
|
|
14057
|
+
var ReactInstrumentation = _dereq_(76);
|
|
14058
|
+
|
|
14059
|
+
var invariant = _dereq_(173);
|
|
13613
14060
|
|
|
13614
14061
|
/**
|
|
13615
14062
|
* Helper to call ReactRef.attachRefs with this composite component, split out
|
|
@@ -13633,12 +14080,20 @@ var ReactReconciler = {
|
|
|
13633
14080
|
* @internal
|
|
13634
14081
|
*/
|
|
13635
14082
|
mountComponent: function (internalInstance, transaction, nativeParent, nativeContainerInfo, context) {
|
|
14083
|
+
if ("development" !== 'production') {
|
|
14084
|
+
if (internalInstance._debugID !== 0) {
|
|
14085
|
+
ReactInstrumentation.debugTool.onBeginReconcilerTimer(internalInstance._debugID, 'mountComponent');
|
|
14086
|
+
}
|
|
14087
|
+
}
|
|
13636
14088
|
var markup = internalInstance.mountComponent(transaction, nativeParent, nativeContainerInfo, context);
|
|
13637
14089
|
if (internalInstance._currentElement && internalInstance._currentElement.ref != null) {
|
|
13638
14090
|
transaction.getReactMountReady().enqueue(attachRefs, internalInstance);
|
|
13639
14091
|
}
|
|
13640
14092
|
if ("development" !== 'production') {
|
|
13641
|
-
|
|
14093
|
+
if (internalInstance._debugID !== 0) {
|
|
14094
|
+
ReactInstrumentation.debugTool.onEndReconcilerTimer(internalInstance._debugID, 'mountComponent');
|
|
14095
|
+
ReactInstrumentation.debugTool.onMountComponent(internalInstance._debugID);
|
|
14096
|
+
}
|
|
13642
14097
|
}
|
|
13643
14098
|
return markup;
|
|
13644
14099
|
},
|
|
@@ -13658,10 +14113,18 @@ var ReactReconciler = {
|
|
|
13658
14113
|
* @internal
|
|
13659
14114
|
*/
|
|
13660
14115
|
unmountComponent: function (internalInstance, safely) {
|
|
14116
|
+
if ("development" !== 'production') {
|
|
14117
|
+
if (internalInstance._debugID !== 0) {
|
|
14118
|
+
ReactInstrumentation.debugTool.onBeginReconcilerTimer(internalInstance._debugID, 'unmountComponent');
|
|
14119
|
+
}
|
|
14120
|
+
}
|
|
13661
14121
|
ReactRef.detachRefs(internalInstance, internalInstance._currentElement);
|
|
13662
14122
|
internalInstance.unmountComponent(safely);
|
|
13663
14123
|
if ("development" !== 'production') {
|
|
13664
|
-
|
|
14124
|
+
if (internalInstance._debugID !== 0) {
|
|
14125
|
+
ReactInstrumentation.debugTool.onEndReconcilerTimer(internalInstance._debugID, 'unmountComponent');
|
|
14126
|
+
ReactInstrumentation.debugTool.onUnmountComponent(internalInstance._debugID);
|
|
14127
|
+
}
|
|
13665
14128
|
}
|
|
13666
14129
|
},
|
|
13667
14130
|
|
|
@@ -13691,6 +14154,12 @@ var ReactReconciler = {
|
|
|
13691
14154
|
return;
|
|
13692
14155
|
}
|
|
13693
14156
|
|
|
14157
|
+
if ("development" !== 'production') {
|
|
14158
|
+
if (internalInstance._debugID !== 0) {
|
|
14159
|
+
ReactInstrumentation.debugTool.onBeginReconcilerTimer(internalInstance._debugID, 'receiveComponent');
|
|
14160
|
+
}
|
|
14161
|
+
}
|
|
14162
|
+
|
|
13694
14163
|
var refsChanged = ReactRef.shouldUpdateRefs(prevElement, nextElement);
|
|
13695
14164
|
|
|
13696
14165
|
if (refsChanged) {
|
|
@@ -13704,7 +14173,10 @@ var ReactReconciler = {
|
|
|
13704
14173
|
}
|
|
13705
14174
|
|
|
13706
14175
|
if ("development" !== 'production') {
|
|
13707
|
-
|
|
14176
|
+
if (internalInstance._debugID !== 0) {
|
|
14177
|
+
ReactInstrumentation.debugTool.onEndReconcilerTimer(internalInstance._debugID, 'receiveComponent');
|
|
14178
|
+
ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID);
|
|
14179
|
+
}
|
|
13708
14180
|
}
|
|
13709
14181
|
},
|
|
13710
14182
|
|
|
@@ -13715,17 +14187,31 @@ var ReactReconciler = {
|
|
|
13715
14187
|
* @param {ReactReconcileTransaction} transaction
|
|
13716
14188
|
* @internal
|
|
13717
14189
|
*/
|
|
13718
|
-
performUpdateIfNecessary: function (internalInstance, transaction) {
|
|
14190
|
+
performUpdateIfNecessary: function (internalInstance, transaction, updateBatchNumber) {
|
|
14191
|
+
if (internalInstance._updateBatchNumber !== updateBatchNumber) {
|
|
14192
|
+
// The component's enqueued batch number should always be the current
|
|
14193
|
+
// batch or the following one.
|
|
14194
|
+
!(internalInstance._updateBatchNumber == null || internalInstance._updateBatchNumber === updateBatchNumber + 1) ? "development" !== 'production' ? invariant(false, 'performUpdateIfNecessary: Unexpected batch number (current %s, ' + 'pending %s)', updateBatchNumber, internalInstance._updateBatchNumber) : invariant(false) : void 0;
|
|
14195
|
+
return;
|
|
14196
|
+
}
|
|
14197
|
+
if ("development" !== 'production') {
|
|
14198
|
+
if (internalInstance._debugID !== 0) {
|
|
14199
|
+
ReactInstrumentation.debugTool.onBeginReconcilerTimer(internalInstance._debugID, 'performUpdateIfNecessary');
|
|
14200
|
+
}
|
|
14201
|
+
}
|
|
13719
14202
|
internalInstance.performUpdateIfNecessary(transaction);
|
|
13720
14203
|
if ("development" !== 'production') {
|
|
13721
|
-
|
|
14204
|
+
if (internalInstance._debugID !== 0) {
|
|
14205
|
+
ReactInstrumentation.debugTool.onEndReconcilerTimer(internalInstance._debugID, 'performUpdateIfNecessary');
|
|
14206
|
+
ReactInstrumentation.debugTool.onUpdateComponent(internalInstance._debugID);
|
|
14207
|
+
}
|
|
13722
14208
|
}
|
|
13723
14209
|
}
|
|
13724
14210
|
|
|
13725
14211
|
};
|
|
13726
14212
|
|
|
13727
14213
|
module.exports = ReactReconciler;
|
|
13728
|
-
},{"
|
|
14214
|
+
},{"173":173,"76":76,"94":94}],94:[function(_dereq_,module,exports){
|
|
13729
14215
|
/**
|
|
13730
14216
|
* Copyright 2013-present, Facebook, Inc.
|
|
13731
14217
|
* All rights reserved.
|
|
@@ -13840,10 +14326,12 @@ module.exports = ReactServerBatchingStrategy;
|
|
|
13840
14326
|
*/
|
|
13841
14327
|
'use strict';
|
|
13842
14328
|
|
|
13843
|
-
var ReactDOMContainerInfo = _dereq_(
|
|
13844
|
-
var ReactDefaultBatchingStrategy = _dereq_(
|
|
13845
|
-
var ReactElement = _dereq_(
|
|
13846
|
-
var
|
|
14329
|
+
var ReactDOMContainerInfo = _dereq_(46);
|
|
14330
|
+
var ReactDefaultBatchingStrategy = _dereq_(63);
|
|
14331
|
+
var ReactElement = _dereq_(65);
|
|
14332
|
+
var ReactInstrumentation = _dereq_(76);
|
|
14333
|
+
var ReactMarkupChecksum = _dereq_(79);
|
|
14334
|
+
var ReactReconciler = _dereq_(93);
|
|
13847
14335
|
var ReactServerBatchingStrategy = _dereq_(95);
|
|
13848
14336
|
var ReactServerRenderingTransaction = _dereq_(97);
|
|
13849
14337
|
var ReactUpdates = _dereq_(104);
|
|
@@ -13864,8 +14352,15 @@ function renderToStringImpl(element, makeStaticMarkup) {
|
|
|
13864
14352
|
transaction = ReactServerRenderingTransaction.getPooled(makeStaticMarkup);
|
|
13865
14353
|
|
|
13866
14354
|
return transaction.perform(function () {
|
|
14355
|
+
if ("development" !== 'production') {
|
|
14356
|
+
ReactInstrumentation.debugTool.onBeginFlush();
|
|
14357
|
+
}
|
|
13867
14358
|
var componentInstance = instantiateReactComponent(element);
|
|
13868
|
-
var markup =
|
|
14359
|
+
var markup = ReactReconciler.mountComponent(componentInstance, transaction, null, ReactDOMContainerInfo(), emptyObject);
|
|
14360
|
+
if ("development" !== 'production') {
|
|
14361
|
+
ReactInstrumentation.debugTool.onUnmountComponent(componentInstance._debugID);
|
|
14362
|
+
ReactInstrumentation.debugTool.onEndFlush();
|
|
14363
|
+
}
|
|
13869
14364
|
if (!makeStaticMarkup) {
|
|
13870
14365
|
markup = ReactMarkupChecksum.addChecksumToMarkup(markup);
|
|
13871
14366
|
}
|
|
@@ -13879,11 +14374,21 @@ function renderToStringImpl(element, makeStaticMarkup) {
|
|
|
13879
14374
|
}
|
|
13880
14375
|
}
|
|
13881
14376
|
|
|
14377
|
+
/**
|
|
14378
|
+
* Render a ReactElement to its initial HTML. This should only be used on the
|
|
14379
|
+
* server.
|
|
14380
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#reactdomserver.rendertostring
|
|
14381
|
+
*/
|
|
13882
14382
|
function renderToString(element) {
|
|
13883
14383
|
!ReactElement.isValidElement(element) ? "development" !== 'production' ? invariant(false, 'renderToString(): You must pass a valid ReactElement.') : invariant(false) : void 0;
|
|
13884
14384
|
return renderToStringImpl(element, false);
|
|
13885
14385
|
}
|
|
13886
14386
|
|
|
14387
|
+
/**
|
|
14388
|
+
* Similar to renderToString, except this doesn't create extra DOM attributes
|
|
14389
|
+
* such as data-react-id that React uses internally.
|
|
14390
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#reactdomserver.rendertostaticmarkup
|
|
14391
|
+
*/
|
|
13887
14392
|
function renderToStaticMarkup(element) {
|
|
13888
14393
|
!ReactElement.isValidElement(element) ? "development" !== 'production' ? invariant(false, 'renderToStaticMarkup(): You must pass a valid ReactElement.') : invariant(false) : void 0;
|
|
13889
14394
|
return renderToStringImpl(element, true);
|
|
@@ -13893,7 +14398,7 @@ module.exports = {
|
|
|
13893
14398
|
renderToString: renderToString,
|
|
13894
14399
|
renderToStaticMarkup: renderToStaticMarkup
|
|
13895
14400
|
};
|
|
13896
|
-
},{"104":104,"144":144,"166":166,"173":173,"
|
|
14401
|
+
},{"104":104,"144":144,"166":166,"173":173,"46":46,"63":63,"65":65,"76":76,"79":79,"93":93,"95":95,"97":97}],97:[function(_dereq_,module,exports){
|
|
13897
14402
|
/**
|
|
13898
14403
|
* Copyright 2014-present, Facebook, Inc.
|
|
13899
14404
|
* All rights reserved.
|
|
@@ -13955,7 +14460,11 @@ var Mixin = {
|
|
|
13955
14460
|
* `PooledClass` looks for this, and will invoke this before allowing this
|
|
13956
14461
|
* instance to be reused.
|
|
13957
14462
|
*/
|
|
13958
|
-
destructor: function () {}
|
|
14463
|
+
destructor: function () {},
|
|
14464
|
+
|
|
14465
|
+
checkpoint: function () {},
|
|
14466
|
+
|
|
14467
|
+
rollback: function () {}
|
|
13959
14468
|
};
|
|
13960
14469
|
|
|
13961
14470
|
_assign(ReactServerRenderingTransaction.prototype, Transaction.Mixin, Mixin);
|
|
@@ -14089,13 +14598,13 @@ var EventPluginHub = _dereq_(17);
|
|
|
14089
14598
|
var EventPluginRegistry = _dereq_(18);
|
|
14090
14599
|
var EventPropagators = _dereq_(20);
|
|
14091
14600
|
var React = _dereq_(27);
|
|
14092
|
-
var ReactDefaultInjection = _dereq_(
|
|
14093
|
-
var ReactDOM = _dereq_(
|
|
14094
|
-
var ReactDOMComponentTree = _dereq_(
|
|
14095
|
-
var ReactElement = _dereq_(
|
|
14601
|
+
var ReactDefaultInjection = _dereq_(64);
|
|
14602
|
+
var ReactDOM = _dereq_(41);
|
|
14603
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
14604
|
+
var ReactElement = _dereq_(65);
|
|
14096
14605
|
var ReactBrowserEventEmitter = _dereq_(28);
|
|
14097
|
-
var ReactCompositeComponent = _dereq_(
|
|
14098
|
-
var ReactInstanceMap = _dereq_(
|
|
14606
|
+
var ReactCompositeComponent = _dereq_(39);
|
|
14607
|
+
var ReactInstanceMap = _dereq_(75);
|
|
14099
14608
|
var ReactUpdates = _dereq_(104);
|
|
14100
14609
|
var SyntheticEvent = _dereq_(115);
|
|
14101
14610
|
|
|
@@ -14134,6 +14643,10 @@ function findAllInRenderedTreeInternal(inst, test) {
|
|
|
14134
14643
|
}
|
|
14135
14644
|
|
|
14136
14645
|
/**
|
|
14646
|
+
* Utilities for making it easy to test React components.
|
|
14647
|
+
*
|
|
14648
|
+
* See https://facebook.github.io/react/docs/test-utils.html
|
|
14649
|
+
*
|
|
14137
14650
|
* Todo: Support the entire DOM.scry query syntax. For now, these simple
|
|
14138
14651
|
* utilities will suffice for testing purposes.
|
|
14139
14652
|
* @lends ReactTestUtils
|
|
@@ -14378,9 +14891,12 @@ ReactShallowRenderer.prototype.getMountedInstance = function () {
|
|
|
14378
14891
|
return this._instance ? this._instance._instance : null;
|
|
14379
14892
|
};
|
|
14380
14893
|
|
|
14894
|
+
var nextDebugID = 1;
|
|
14895
|
+
|
|
14381
14896
|
var NoopInternalComponent = function (element) {
|
|
14382
14897
|
this._renderedOutput = element;
|
|
14383
14898
|
this._currentElement = element;
|
|
14899
|
+
this._debugID = nextDebugID++;
|
|
14384
14900
|
};
|
|
14385
14901
|
|
|
14386
14902
|
NoopInternalComponent.prototype = {
|
|
@@ -14404,6 +14920,7 @@ NoopInternalComponent.prototype = {
|
|
|
14404
14920
|
};
|
|
14405
14921
|
|
|
14406
14922
|
var ShallowComponentWrapper = function (element) {
|
|
14923
|
+
this._debugID = nextDebugID++;
|
|
14407
14924
|
this.construct(element);
|
|
14408
14925
|
};
|
|
14409
14926
|
_assign(ShallowComponentWrapper.prototype, ReactCompositeComponent.Mixin, {
|
|
@@ -14568,7 +15085,7 @@ Object.keys(topLevelTypes).forEach(function (eventType) {
|
|
|
14568
15085
|
});
|
|
14569
15086
|
|
|
14570
15087
|
module.exports = ReactTestUtils;
|
|
14571
|
-
},{"104":104,"115":115,"132":132,"16":16,"166":166,"17":17,"173":173,"18":18,"184":184,"20":20,"27":27,"28":28,"
|
|
15088
|
+
},{"104":104,"115":115,"132":132,"16":16,"166":166,"17":17,"173":173,"18":18,"184":184,"20":20,"27":27,"28":28,"39":39,"41":41,"45":45,"64":64,"65":65,"75":75}],100:[function(_dereq_,module,exports){
|
|
14572
15089
|
/**
|
|
14573
15090
|
* Copyright 2013-present, Facebook, Inc.
|
|
14574
15091
|
* All rights reserved.
|
|
@@ -14761,6 +15278,11 @@ var ReactTransitionChildMapping = _dereq_(100);
|
|
|
14761
15278
|
|
|
14762
15279
|
var emptyFunction = _dereq_(165);
|
|
14763
15280
|
|
|
15281
|
+
/**
|
|
15282
|
+
* A basis for animatins. When children are declaratively added or removed,
|
|
15283
|
+
* special lifecycle hooks are called.
|
|
15284
|
+
* See https://facebook.github.io/react/docs/animation.html#low-level-api-reacttransitiongroup
|
|
15285
|
+
*/
|
|
14764
15286
|
var ReactTransitionGroup = React.createClass({
|
|
14765
15287
|
displayName: 'ReactTransitionGroup',
|
|
14766
15288
|
|
|
@@ -14961,8 +15483,8 @@ module.exports = ReactTransitionGroup;
|
|
|
14961
15483
|
|
|
14962
15484
|
'use strict';
|
|
14963
15485
|
|
|
14964
|
-
var ReactCurrentOwner = _dereq_(
|
|
14965
|
-
var ReactInstanceMap = _dereq_(
|
|
15486
|
+
var ReactCurrentOwner = _dereq_(40);
|
|
15487
|
+
var ReactInstanceMap = _dereq_(75);
|
|
14966
15488
|
var ReactUpdates = _dereq_(104);
|
|
14967
15489
|
|
|
14968
15490
|
var invariant = _dereq_(173);
|
|
@@ -15163,7 +15685,7 @@ var ReactUpdateQueue = {
|
|
|
15163
15685
|
};
|
|
15164
15686
|
|
|
15165
15687
|
module.exports = ReactUpdateQueue;
|
|
15166
|
-
},{"104":104,"173":173,"183":183,"
|
|
15688
|
+
},{"104":104,"173":173,"183":183,"40":40,"75":75}],104:[function(_dereq_,module,exports){
|
|
15167
15689
|
/**
|
|
15168
15690
|
* Copyright 2013-present, Facebook, Inc.
|
|
15169
15691
|
* All rights reserved.
|
|
@@ -15181,14 +15703,15 @@ var _assign = _dereq_(184);
|
|
|
15181
15703
|
|
|
15182
15704
|
var CallbackQueue = _dereq_(5);
|
|
15183
15705
|
var PooledClass = _dereq_(26);
|
|
15184
|
-
var ReactFeatureFlags = _dereq_(
|
|
15185
|
-
var
|
|
15706
|
+
var ReactFeatureFlags = _dereq_(71);
|
|
15707
|
+
var ReactInstrumentation = _dereq_(76);
|
|
15186
15708
|
var ReactReconciler = _dereq_(93);
|
|
15187
15709
|
var Transaction = _dereq_(124);
|
|
15188
15710
|
|
|
15189
15711
|
var invariant = _dereq_(173);
|
|
15190
15712
|
|
|
15191
15713
|
var dirtyComponents = [];
|
|
15714
|
+
var updateBatchNumber = 0;
|
|
15192
15715
|
var asapCallbackQueue = CallbackQueue.getPooled();
|
|
15193
15716
|
var asapEnqueued = false;
|
|
15194
15717
|
|
|
@@ -15283,6 +15806,13 @@ function runBatchedUpdates(transaction) {
|
|
|
15283
15806
|
// them before their children by sorting the array.
|
|
15284
15807
|
dirtyComponents.sort(mountOrderComparator);
|
|
15285
15808
|
|
|
15809
|
+
// Any updates enqueued while reconciling must be performed after this entire
|
|
15810
|
+
// batch. Otherwise, if dirtyComponents is [A, B] where A has children B and
|
|
15811
|
+
// C, B could update twice in a single batch if C's render enqueues an update
|
|
15812
|
+
// to B (since B would have already updated, we should skip it, and the only
|
|
15813
|
+
// way we can know to do so is by checking the batch counter).
|
|
15814
|
+
updateBatchNumber++;
|
|
15815
|
+
|
|
15286
15816
|
for (var i = 0; i < len; i++) {
|
|
15287
15817
|
// If a component is unmounted before pending changes apply, it will still
|
|
15288
15818
|
// be here, but we assume that it has cleared its _pendingCallbacks and
|
|
@@ -15306,7 +15836,7 @@ function runBatchedUpdates(transaction) {
|
|
|
15306
15836
|
console.time(markerName);
|
|
15307
15837
|
}
|
|
15308
15838
|
|
|
15309
|
-
ReactReconciler.performUpdateIfNecessary(component, transaction.reconcileTransaction);
|
|
15839
|
+
ReactReconciler.performUpdateIfNecessary(component, transaction.reconcileTransaction, updateBatchNumber);
|
|
15310
15840
|
|
|
15311
15841
|
if (markerName) {
|
|
15312
15842
|
console.timeEnd(markerName);
|
|
@@ -15321,6 +15851,10 @@ function runBatchedUpdates(transaction) {
|
|
|
15321
15851
|
}
|
|
15322
15852
|
|
|
15323
15853
|
var flushBatchedUpdates = function () {
|
|
15854
|
+
if ("development" !== 'production') {
|
|
15855
|
+
ReactInstrumentation.debugTool.onBeginFlush();
|
|
15856
|
+
}
|
|
15857
|
+
|
|
15324
15858
|
// ReactUpdatesFlushTransaction's wrappers will clear the dirtyComponents
|
|
15325
15859
|
// array and perform any updates enqueued by mount-ready handlers (i.e.,
|
|
15326
15860
|
// componentDidUpdate) but we need to check here too in order to catch
|
|
@@ -15340,8 +15874,11 @@ var flushBatchedUpdates = function () {
|
|
|
15340
15874
|
CallbackQueue.release(queue);
|
|
15341
15875
|
}
|
|
15342
15876
|
}
|
|
15877
|
+
|
|
15878
|
+
if ("development" !== 'production') {
|
|
15879
|
+
ReactInstrumentation.debugTool.onEndFlush();
|
|
15880
|
+
}
|
|
15343
15881
|
};
|
|
15344
|
-
flushBatchedUpdates = ReactPerf.measure('ReactUpdates', 'flushBatchedUpdates', flushBatchedUpdates);
|
|
15345
15882
|
|
|
15346
15883
|
/**
|
|
15347
15884
|
* Mark a component as needing a rerender, adding an optional callback to a
|
|
@@ -15362,6 +15899,9 @@ function enqueueUpdate(component) {
|
|
|
15362
15899
|
}
|
|
15363
15900
|
|
|
15364
15901
|
dirtyComponents.push(component);
|
|
15902
|
+
if (component._updateBatchNumber == null) {
|
|
15903
|
+
component._updateBatchNumber = updateBatchNumber + 1;
|
|
15904
|
+
}
|
|
15365
15905
|
}
|
|
15366
15906
|
|
|
15367
15907
|
/**
|
|
@@ -15405,7 +15945,7 @@ var ReactUpdates = {
|
|
|
15405
15945
|
};
|
|
15406
15946
|
|
|
15407
15947
|
module.exports = ReactUpdates;
|
|
15408
|
-
},{"124":124,"173":173,"184":184,"26":26,"5":5,"
|
|
15948
|
+
},{"124":124,"173":173,"184":184,"26":26,"5":5,"71":71,"76":76,"93":93}],105:[function(_dereq_,module,exports){
|
|
15409
15949
|
/**
|
|
15410
15950
|
* Copyright 2013-present, Facebook, Inc.
|
|
15411
15951
|
* All rights reserved.
|
|
@@ -15419,7 +15959,7 @@ module.exports = ReactUpdates;
|
|
|
15419
15959
|
|
|
15420
15960
|
'use strict';
|
|
15421
15961
|
|
|
15422
|
-
module.exports = '15.0
|
|
15962
|
+
module.exports = '15.1.0';
|
|
15423
15963
|
},{}],106:[function(_dereq_,module,exports){
|
|
15424
15964
|
/**
|
|
15425
15965
|
* Copyright 2013-present, Facebook, Inc.
|
|
@@ -15436,9 +15976,9 @@ module.exports = '15.0.2';
|
|
|
15436
15976
|
|
|
15437
15977
|
var LinkedStateMixin = _dereq_(24);
|
|
15438
15978
|
var React = _dereq_(27);
|
|
15439
|
-
var ReactComponentWithPureRenderMixin = _dereq_(
|
|
15979
|
+
var ReactComponentWithPureRenderMixin = _dereq_(38);
|
|
15440
15980
|
var ReactCSSTransitionGroup = _dereq_(29);
|
|
15441
|
-
var ReactFragment = _dereq_(
|
|
15981
|
+
var ReactFragment = _dereq_(72);
|
|
15442
15982
|
var ReactTransitionGroup = _dereq_(102);
|
|
15443
15983
|
|
|
15444
15984
|
var shallowCompare = _dereq_(152);
|
|
@@ -15456,12 +15996,12 @@ React.addons = {
|
|
|
15456
15996
|
};
|
|
15457
15997
|
|
|
15458
15998
|
if ("development" !== 'production') {
|
|
15459
|
-
React.addons.Perf = _dereq_(
|
|
15999
|
+
React.addons.Perf = _dereq_(88);
|
|
15460
16000
|
React.addons.TestUtils = _dereq_(99);
|
|
15461
16001
|
}
|
|
15462
16002
|
|
|
15463
16003
|
module.exports = React;
|
|
15464
|
-
},{"102":102,"152":152,"155":155,"24":24,"27":27,"29":29,"
|
|
16004
|
+
},{"102":102,"152":152,"155":155,"24":24,"27":27,"29":29,"38":38,"72":72,"88":88,"99":99}],107:[function(_dereq_,module,exports){
|
|
15465
16005
|
/**
|
|
15466
16006
|
* Copyright 2013-present, Facebook, Inc.
|
|
15467
16007
|
* All rights reserved.
|
|
@@ -15477,8 +16017,8 @@ module.exports = React;
|
|
|
15477
16017
|
|
|
15478
16018
|
var _assign = _dereq_(184);
|
|
15479
16019
|
|
|
15480
|
-
var ReactDOM = _dereq_(
|
|
15481
|
-
var ReactDOMServer = _dereq_(
|
|
16020
|
+
var ReactDOM = _dereq_(41);
|
|
16021
|
+
var ReactDOMServer = _dereq_(57);
|
|
15482
16022
|
var ReactWithAddons = _dereq_(106);
|
|
15483
16023
|
|
|
15484
16024
|
// `version` will be added here by ReactIsomorphic.
|
|
@@ -15488,7 +16028,7 @@ var ReactWithAddonsUMDEntry = _assign({
|
|
|
15488
16028
|
}, ReactWithAddons);
|
|
15489
16029
|
|
|
15490
16030
|
module.exports = ReactWithAddonsUMDEntry;
|
|
15491
|
-
},{"106":106,"184":184,"
|
|
16031
|
+
},{"106":106,"184":184,"41":41,"57":57}],108:[function(_dereq_,module,exports){
|
|
15492
16032
|
/**
|
|
15493
16033
|
* Copyright 2013-present, Facebook, Inc.
|
|
15494
16034
|
* All rights reserved.
|
|
@@ -15806,8 +16346,8 @@ module.exports = SVGDOMPropertyConfig;
|
|
|
15806
16346
|
var EventConstants = _dereq_(16);
|
|
15807
16347
|
var EventPropagators = _dereq_(20);
|
|
15808
16348
|
var ExecutionEnvironment = _dereq_(159);
|
|
15809
|
-
var ReactDOMComponentTree = _dereq_(
|
|
15810
|
-
var ReactInputSelection = _dereq_(
|
|
16349
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
16350
|
+
var ReactInputSelection = _dereq_(74);
|
|
15811
16351
|
var SyntheticEvent = _dereq_(115);
|
|
15812
16352
|
|
|
15813
16353
|
var getActiveElement = _dereq_(168);
|
|
@@ -15986,7 +16526,7 @@ var SelectEventPlugin = {
|
|
|
15986
16526
|
};
|
|
15987
16527
|
|
|
15988
16528
|
module.exports = SelectEventPlugin;
|
|
15989
|
-
},{"115":115,"146":146,"159":159,"16":16,"168":168,"177":177,"182":182,"20":20,"
|
|
16529
|
+
},{"115":115,"146":146,"159":159,"16":16,"168":168,"177":177,"182":182,"20":20,"45":45,"74":74}],110:[function(_dereq_,module,exports){
|
|
15990
16530
|
/**
|
|
15991
16531
|
* Copyright 2013-present, Facebook, Inc.
|
|
15992
16532
|
* All rights reserved.
|
|
@@ -16003,7 +16543,7 @@ module.exports = SelectEventPlugin;
|
|
|
16003
16543
|
var EventConstants = _dereq_(16);
|
|
16004
16544
|
var EventListener = _dereq_(158);
|
|
16005
16545
|
var EventPropagators = _dereq_(20);
|
|
16006
|
-
var ReactDOMComponentTree = _dereq_(
|
|
16546
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
16007
16547
|
var SyntheticAnimationEvent = _dereq_(111);
|
|
16008
16548
|
var SyntheticClipboardEvent = _dereq_(112);
|
|
16009
16549
|
var SyntheticEvent = _dereq_(115);
|
|
@@ -16614,7 +17154,7 @@ var SimpleEventPlugin = {
|
|
|
16614
17154
|
};
|
|
16615
17155
|
|
|
16616
17156
|
module.exports = SimpleEventPlugin;
|
|
16617
|
-
},{"111":111,"112":112,"114":114,"115":115,"116":116,"118":118,"119":119,"120":120,"121":121,"122":122,"123":123,"135":135,"158":158,"16":16,"165":165,"173":173,"177":177,"20":20,"
|
|
17157
|
+
},{"111":111,"112":112,"114":114,"115":115,"116":116,"118":118,"119":119,"120":120,"121":121,"122":122,"123":123,"135":135,"158":158,"16":16,"165":165,"173":173,"177":177,"20":20,"45":45}],111:[function(_dereq_,module,exports){
|
|
16618
17158
|
/**
|
|
16619
17159
|
* Copyright 2013-present, Facebook, Inc.
|
|
16620
17160
|
* All rights reserved.
|
|
@@ -18016,9 +18556,9 @@ module.exports = escapeTextContentForBrowser;
|
|
|
18016
18556
|
|
|
18017
18557
|
'use strict';
|
|
18018
18558
|
|
|
18019
|
-
var ReactCurrentOwner = _dereq_(
|
|
18020
|
-
var ReactDOMComponentTree = _dereq_(
|
|
18021
|
-
var ReactInstanceMap = _dereq_(
|
|
18559
|
+
var ReactCurrentOwner = _dereq_(40);
|
|
18560
|
+
var ReactDOMComponentTree = _dereq_(45);
|
|
18561
|
+
var ReactInstanceMap = _dereq_(75);
|
|
18022
18562
|
|
|
18023
18563
|
var getNativeComponentFromComposite = _dereq_(140);
|
|
18024
18564
|
var invariant = _dereq_(173);
|
|
@@ -18027,6 +18567,8 @@ var warning = _dereq_(183);
|
|
|
18027
18567
|
/**
|
|
18028
18568
|
* Returns the DOM node rendered by this element.
|
|
18029
18569
|
*
|
|
18570
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#reactdom.finddomnode
|
|
18571
|
+
*
|
|
18030
18572
|
* @param {ReactComponent|DOMElement} componentOrElement
|
|
18031
18573
|
* @return {?DOMElement} The root node of this element.
|
|
18032
18574
|
*/
|
|
@@ -18059,7 +18601,7 @@ function findDOMNode(componentOrElement) {
|
|
|
18059
18601
|
}
|
|
18060
18602
|
|
|
18061
18603
|
module.exports = findDOMNode;
|
|
18062
|
-
},{"140":140,"173":173,"183":183,"
|
|
18604
|
+
},{"140":140,"173":173,"183":183,"40":40,"45":45,"75":75}],133:[function(_dereq_,module,exports){
|
|
18063
18605
|
/**
|
|
18064
18606
|
* Copyright 2013-present, Facebook, Inc.
|
|
18065
18607
|
* All rights reserved.
|
|
@@ -18673,9 +19215,10 @@ module.exports = getVendorPrefixedEventName;
|
|
|
18673
19215
|
|
|
18674
19216
|
var _assign = _dereq_(184);
|
|
18675
19217
|
|
|
18676
|
-
var ReactCompositeComponent = _dereq_(
|
|
18677
|
-
var ReactEmptyComponent = _dereq_(
|
|
18678
|
-
var ReactNativeComponent = _dereq_(
|
|
19218
|
+
var ReactCompositeComponent = _dereq_(39);
|
|
19219
|
+
var ReactEmptyComponent = _dereq_(67);
|
|
19220
|
+
var ReactNativeComponent = _dereq_(83);
|
|
19221
|
+
var ReactInstrumentation = _dereq_(76);
|
|
18679
19222
|
|
|
18680
19223
|
var invariant = _dereq_(173);
|
|
18681
19224
|
var warning = _dereq_(183);
|
|
@@ -18698,6 +19241,21 @@ function getDeclarationErrorAddendum(owner) {
|
|
|
18698
19241
|
return '';
|
|
18699
19242
|
}
|
|
18700
19243
|
|
|
19244
|
+
function getDisplayName(instance) {
|
|
19245
|
+
var element = instance._currentElement;
|
|
19246
|
+
if (element == null) {
|
|
19247
|
+
return '#empty';
|
|
19248
|
+
} else if (typeof element === 'string' || typeof element === 'number') {
|
|
19249
|
+
return '#text';
|
|
19250
|
+
} else if (typeof element.type === 'string') {
|
|
19251
|
+
return element.type;
|
|
19252
|
+
} else if (instance.getName) {
|
|
19253
|
+
return instance.getName() || 'Unknown';
|
|
19254
|
+
} else {
|
|
19255
|
+
return element.type.displayName || element.type.name || 'Unknown';
|
|
19256
|
+
}
|
|
19257
|
+
}
|
|
19258
|
+
|
|
18701
19259
|
/**
|
|
18702
19260
|
* Check if the type reference is a known internal type. I.e. not a user
|
|
18703
19261
|
* provided composite type.
|
|
@@ -18709,6 +19267,8 @@ function isInternalComponentType(type) {
|
|
|
18709
19267
|
return typeof type === 'function' && typeof type.prototype !== 'undefined' && typeof type.prototype.mountComponent === 'function' && typeof type.prototype.receiveComponent === 'function';
|
|
18710
19268
|
}
|
|
18711
19269
|
|
|
19270
|
+
var nextDebugID = 1;
|
|
19271
|
+
|
|
18712
19272
|
/**
|
|
18713
19273
|
* Given a ReactNode, create an instance that will actually be mounted.
|
|
18714
19274
|
*
|
|
@@ -18719,7 +19279,8 @@ function isInternalComponentType(type) {
|
|
|
18719
19279
|
function instantiateReactComponent(node) {
|
|
18720
19280
|
var instance;
|
|
18721
19281
|
|
|
18722
|
-
|
|
19282
|
+
var isEmpty = node === null || node === false;
|
|
19283
|
+
if (isEmpty) {
|
|
18723
19284
|
instance = ReactEmptyComponent.create(instantiateReactComponent);
|
|
18724
19285
|
} else if (typeof node === 'object') {
|
|
18725
19286
|
var element = node;
|
|
@@ -18757,6 +19318,20 @@ function instantiateReactComponent(node) {
|
|
|
18757
19318
|
instance._warnedAboutRefsInRender = false;
|
|
18758
19319
|
}
|
|
18759
19320
|
|
|
19321
|
+
if ("development" !== 'production') {
|
|
19322
|
+
var debugID = isEmpty ? 0 : nextDebugID++;
|
|
19323
|
+
instance._debugID = debugID;
|
|
19324
|
+
|
|
19325
|
+
if (debugID !== 0) {
|
|
19326
|
+
var displayName = getDisplayName(instance);
|
|
19327
|
+
ReactInstrumentation.debugTool.onSetDisplayName(debugID, displayName);
|
|
19328
|
+
var owner = node && node._owner;
|
|
19329
|
+
if (owner) {
|
|
19330
|
+
ReactInstrumentation.debugTool.onSetOwner(debugID, owner._debugID);
|
|
19331
|
+
}
|
|
19332
|
+
}
|
|
19333
|
+
}
|
|
19334
|
+
|
|
18760
19335
|
// Internal instances should fully constructed at this point, so they should
|
|
18761
19336
|
// not get any new fields added to them at this point.
|
|
18762
19337
|
if ("development" !== 'production') {
|
|
@@ -18769,7 +19344,7 @@ function instantiateReactComponent(node) {
|
|
|
18769
19344
|
}
|
|
18770
19345
|
|
|
18771
19346
|
module.exports = instantiateReactComponent;
|
|
18772
|
-
},{"173":173,"183":183,"184":184,"
|
|
19347
|
+
},{"173":173,"183":183,"184":184,"39":39,"67":67,"76":76,"83":83}],145:[function(_dereq_,module,exports){
|
|
18773
19348
|
/**
|
|
18774
19349
|
* Copyright 2013-present, Facebook, Inc.
|
|
18775
19350
|
* All rights reserved.
|
|
@@ -18885,16 +19460,19 @@ module.exports = isTextInputElement;
|
|
|
18885
19460
|
*/
|
|
18886
19461
|
'use strict';
|
|
18887
19462
|
|
|
18888
|
-
var ReactElement = _dereq_(
|
|
19463
|
+
var ReactElement = _dereq_(65);
|
|
18889
19464
|
|
|
18890
19465
|
var invariant = _dereq_(173);
|
|
18891
19466
|
|
|
18892
19467
|
/**
|
|
18893
19468
|
* Returns the first child in a collection of children and verifies that there
|
|
18894
|
-
* is only one child in the collection.
|
|
18895
|
-
*
|
|
18896
|
-
*
|
|
18897
|
-
*
|
|
19469
|
+
* is only one child in the collection.
|
|
19470
|
+
*
|
|
19471
|
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.children.only
|
|
19472
|
+
*
|
|
19473
|
+
* The current implementation of this function assumes that a single child gets
|
|
19474
|
+
* passed without a wrapper, but the purpose of this helper function is to
|
|
19475
|
+
* abstract away the particular structure of children.
|
|
18898
19476
|
*
|
|
18899
19477
|
* @param {?object} children Child collection structure.
|
|
18900
19478
|
* @return {ReactElement} The first and only `ReactElement` contained in the
|
|
@@ -18906,7 +19484,7 @@ function onlyChild(children) {
|
|
|
18906
19484
|
}
|
|
18907
19485
|
|
|
18908
19486
|
module.exports = onlyChild;
|
|
18909
|
-
},{"173":173,"
|
|
19487
|
+
},{"173":173,"65":65}],148:[function(_dereq_,module,exports){
|
|
18910
19488
|
/**
|
|
18911
19489
|
* Copyright 2013-present, Facebook, Inc.
|
|
18912
19490
|
* All rights reserved.
|
|
@@ -18947,10 +19525,10 @@ module.exports = quoteAttributeValueForBrowser;
|
|
|
18947
19525
|
|
|
18948
19526
|
'use strict';
|
|
18949
19527
|
|
|
18950
|
-
var ReactMount = _dereq_(
|
|
19528
|
+
var ReactMount = _dereq_(80);
|
|
18951
19529
|
|
|
18952
19530
|
module.exports = ReactMount.renderSubtreeIntoContainer;
|
|
18953
|
-
},{"
|
|
19531
|
+
},{"80":80}],150:[function(_dereq_,module,exports){
|
|
18954
19532
|
/**
|
|
18955
19533
|
* Copyright 2013-present, Facebook, Inc.
|
|
18956
19534
|
* All rights reserved.
|
|
@@ -19093,6 +19671,7 @@ var shallowEqual = _dereq_(182);
|
|
|
19093
19671
|
/**
|
|
19094
19672
|
* Does a shallow comparison for props and state.
|
|
19095
19673
|
* See ReactComponentWithPureRenderMixin
|
|
19674
|
+
* See also https://facebook.github.io/react/docs/shallow-compare.html
|
|
19096
19675
|
*/
|
|
19097
19676
|
function shallowCompare(instance, nextProps, nextState) {
|
|
19098
19677
|
return !shallowEqual(instance.props, nextProps) || !shallowEqual(instance.state, nextState);
|
|
@@ -19156,8 +19735,8 @@ module.exports = shouldUpdateReactComponent;
|
|
|
19156
19735
|
|
|
19157
19736
|
'use strict';
|
|
19158
19737
|
|
|
19159
|
-
var ReactCurrentOwner = _dereq_(
|
|
19160
|
-
var ReactElement = _dereq_(
|
|
19738
|
+
var ReactCurrentOwner = _dereq_(40);
|
|
19739
|
+
var ReactElement = _dereq_(65);
|
|
19161
19740
|
|
|
19162
19741
|
var getIteratorFn = _dereq_(139);
|
|
19163
19742
|
var invariant = _dereq_(173);
|
|
@@ -19301,7 +19880,7 @@ function traverseAllChildren(children, callback, traverseContext) {
|
|
|
19301
19880
|
}
|
|
19302
19881
|
|
|
19303
19882
|
module.exports = traverseAllChildren;
|
|
19304
|
-
},{"139":139,"173":173,"183":183,"23":23,"
|
|
19883
|
+
},{"139":139,"173":173,"183":183,"23":23,"40":40,"65":65}],155:[function(_dereq_,module,exports){
|
|
19305
19884
|
/**
|
|
19306
19885
|
* Copyright 2013-present, Facebook, Inc.
|
|
19307
19886
|
* All rights reserved.
|
|
@@ -19354,6 +19933,10 @@ function invariantArrayCase(value, spec, command) {
|
|
|
19354
19933
|
!Array.isArray(specValue) ? "development" !== 'production' ? invariant(false, 'update(): expected spec of %s to be an array; got %s. ' + 'Did you forget to wrap your parameter in an array?', command, specValue) : invariant(false) : void 0;
|
|
19355
19934
|
}
|
|
19356
19935
|
|
|
19936
|
+
/**
|
|
19937
|
+
* Returns a updated shallow copy of an object without mutating the original.
|
|
19938
|
+
* See https://facebook.github.io/react/docs/update.html for details.
|
|
19939
|
+
*/
|
|
19357
19940
|
function update(value, spec) {
|
|
19358
19941
|
!(typeof spec === 'object') ? "development" !== 'production' ? invariant(false, 'update(): You provided a key path to update() that did not contain one ' + 'of %s. Did you forget to include {%s: ...}?', ALL_COMMANDS_LIST.join(', '), COMMAND_SET) : invariant(false) : void 0;
|
|
19359
19942
|
|
|
@@ -21121,8 +21704,8 @@ if ("development" !== 'production') {
|
|
|
21121
21704
|
|
|
21122
21705
|
module.exports = warning;
|
|
21123
21706
|
},{"165":165}],184:[function(_dereq_,module,exports){
|
|
21124
|
-
/* eslint-disable no-unused-vars */
|
|
21125
21707
|
'use strict';
|
|
21708
|
+
/* eslint-disable no-unused-vars */
|
|
21126
21709
|
var hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
21127
21710
|
var propIsEnumerable = Object.prototype.propertyIsEnumerable;
|
|
21128
21711
|
|
|
@@ -21134,7 +21717,51 @@ function toObject(val) {
|
|
|
21134
21717
|
return Object(val);
|
|
21135
21718
|
}
|
|
21136
21719
|
|
|
21137
|
-
|
|
21720
|
+
function shouldUseNative() {
|
|
21721
|
+
try {
|
|
21722
|
+
if (!Object.assign) {
|
|
21723
|
+
return false;
|
|
21724
|
+
}
|
|
21725
|
+
|
|
21726
|
+
// Detect buggy property enumeration order in older V8 versions.
|
|
21727
|
+
|
|
21728
|
+
// https://bugs.chromium.org/p/v8/issues/detail?id=4118
|
|
21729
|
+
var test1 = new String('abc'); // eslint-disable-line
|
|
21730
|
+
test1[5] = 'de';
|
|
21731
|
+
if (Object.getOwnPropertyNames(test1)[0] === '5') {
|
|
21732
|
+
return false;
|
|
21733
|
+
}
|
|
21734
|
+
|
|
21735
|
+
// https://bugs.chromium.org/p/v8/issues/detail?id=3056
|
|
21736
|
+
var test2 = {};
|
|
21737
|
+
for (var i = 0; i < 10; i++) {
|
|
21738
|
+
test2['_' + String.fromCharCode(i)] = i;
|
|
21739
|
+
}
|
|
21740
|
+
var order2 = Object.getOwnPropertyNames(test2).map(function (n) {
|
|
21741
|
+
return test2[n];
|
|
21742
|
+
});
|
|
21743
|
+
if (order2.join('') !== '0123456789') {
|
|
21744
|
+
return false;
|
|
21745
|
+
}
|
|
21746
|
+
|
|
21747
|
+
// https://bugs.chromium.org/p/v8/issues/detail?id=3056
|
|
21748
|
+
var test3 = {};
|
|
21749
|
+
'abcdefghijklmnopqrst'.split('').forEach(function (letter) {
|
|
21750
|
+
test3[letter] = letter;
|
|
21751
|
+
});
|
|
21752
|
+
if (Object.keys(Object.assign({}, test3)).join('') !==
|
|
21753
|
+
'abcdefghijklmnopqrst') {
|
|
21754
|
+
return false;
|
|
21755
|
+
}
|
|
21756
|
+
|
|
21757
|
+
return true;
|
|
21758
|
+
} catch (e) {
|
|
21759
|
+
// We don't expect any of the above to throw, but better to be safe.
|
|
21760
|
+
return false;
|
|
21761
|
+
}
|
|
21762
|
+
}
|
|
21763
|
+
|
|
21764
|
+
module.exports = shouldUseNative() ? Object.assign : function (target, source) {
|
|
21138
21765
|
var from;
|
|
21139
21766
|
var to = toObject(target);
|
|
21140
21767
|
var symbols;
|