Skip to content

Commit

Permalink
Fixes #3: Update react to 15.5 (#35)
Browse files Browse the repository at this point in the history
* Run react codemods

* Update react 15.5

* fix proptypes manually

* fix yarn url

* fix order
  • Loading branch information
saminzadeh authored Jun 13, 2017
1 parent 4489f47 commit c30737e
Show file tree
Hide file tree
Showing 34 changed files with 79 additions and 45 deletions.
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,14 @@
"lodash": "^4.17.2",
"moment": "^2.14.1",
"prettier": "^0.22.0",
"prop-types": "^15.5.10",
"query-string": "^4.2.3",
"react": "^15.4.2",
"react": "^15.5.0",
"react-addons-perf": "^15.4.1",
"react-addons-shallow-compare": "^15.3.2",
"react-addons-test-utils": "^15.3.1",
"react-dimensions": "^1.3.0",
"react-dom": "^15.4.1",
"react-dom": "^15.5.0",
"react-ga": "^2.1.2",
"react-helmet": "^3.1.0",
"react-immutable-proptypes": "^2.1.0",
Expand Down
3 changes: 2 additions & 1 deletion src/components/App/NotFound.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';
import { Link } from 'react-router';

export default function NotFound({ error }) {
Expand Down
3 changes: 2 additions & 1 deletion src/components/App/Page.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';
import Helmet from 'react-helmet';
import { Sticky, StickyContainer } from 'react-sticky';

Expand Down
3 changes: 2 additions & 1 deletion src/components/App/TraceIDSearchInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes, Component } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { withRouter } from 'react-router';

class TraceIDSearchInput extends Component {
Expand Down
3 changes: 2 additions & 1 deletion src/components/App/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { Component, PropTypes } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { Provider } from 'react-redux';
import { Router, Route, IndexRedirect, browserHistory } from 'react-router';
import { syncHistoryWithStore } from 'react-router-redux';
Expand Down
3 changes: 2 additions & 1 deletion src/components/DependencyGraph/DAG.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';
import cytoscape from 'cytoscape';
import cydagre from 'cytoscape-dagre';
import dagre from 'dagre';
Expand Down
3 changes: 2 additions & 1 deletion src/components/DependencyGraph/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { Component, PropTypes } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import { Menu } from 'semantic-ui-react';
Expand Down
3 changes: 2 additions & 1 deletion src/components/SearchTracePage/SearchDropdownInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes, Component } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { Dropdown } from 'semantic-ui-react';

/**
Expand Down
3 changes: 2 additions & 1 deletion src/components/SearchTracePage/TraceResultsScatterPlot.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';
import moment from 'moment';
import { XYPlot, XAxis, YAxis, MarkSeries } from 'react-vis';
import 'react-vis/main.css';
Expand Down
3 changes: 2 additions & 1 deletion src/components/SearchTracePage/TraceSearchForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import { Field, reduxForm, formValueSelector } from 'redux-form';
Expand Down
3 changes: 2 additions & 1 deletion src/components/SearchTracePage/TraceSearchResult.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';
import { sortBy } from 'lodash';
import moment from 'moment';

Expand Down
3 changes: 2 additions & 1 deletion src/components/SearchTracePage/TraceServiceTag.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';
import colorGenerator from '../../utils/color-generator';

export default function TraceServiceTag({ service }) {
Expand Down
3 changes: 2 additions & 1 deletion src/components/SearchTracePage/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes, Component } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import { Field, reduxForm, formValueSelector } from 'redux-form';
Expand Down
3 changes: 2 additions & 1 deletion src/components/SpanGraph/SpanGraphSpan.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { Component, PropTypes } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import shallowCompare from 'react-addons-shallow-compare';

import spanPropTypes from '../../propTypes/span';
Expand Down
3 changes: 2 additions & 1 deletion src/components/SpanGraph/SpanGraphTick.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { Component, PropTypes } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { isEqual } from 'lodash';

import spanGraphTickPropTypes from '../../propTypes/spanGraphTick';
Expand Down
3 changes: 2 additions & 1 deletion src/components/SpanGraph/SpanGraphTickHeader.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { Component, PropTypes } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { isEqual } from 'lodash';

import tracePropTypes from '../../propTypes/trace';
Expand Down
3 changes: 2 additions & 1 deletion src/components/SpanGraph/SpanGraphTickHeaderLabel.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';

import tracePropTypes from '../../propTypes/trace';
import { formatDurationForTrace } from '../../selectors/trace';
Expand Down
3 changes: 2 additions & 1 deletion src/components/SpanGraph/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { Children, PropTypes } from 'react';
import PropTypes from 'prop-types';
import React, { Children } from 'react';

import './SpanGraph.css';
import SpanGraphTick from './SpanGraphTick';
Expand Down
3 changes: 2 additions & 1 deletion src/components/TracePage/TimelineScrubber.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';

import tracePropTypes from '../../propTypes/trace';
import { getTraceTimestamp, getTraceDuration } from '../../selectors/trace';
Expand Down
3 changes: 2 additions & 1 deletion src/components/TracePage/TracePageHeader.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';
import { Dropdown, Menu } from 'semantic-ui-react';

import tracePropTypes from '../../propTypes/trace';
Expand Down
3 changes: 2 additions & 1 deletion src/components/TracePage/TracePageTimeline.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { Component, PropTypes } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { window } from 'global';

import SpanGraph from '../SpanGraph';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';
import SpanGraphTick from '../../SpanGraph/SpanGraphTick';
import logPropTypes from '../../../propTypes/log';

Expand Down
5 changes: 3 additions & 2 deletions src/components/TracePage/TraceTimelineViewer/SpanDetail.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { PropTypes } from 'react';
import PropTypes from 'prop-types';
import React from 'react';
import { withState } from 'recompose';

import jsonMarkup from 'json-markup';
Expand Down Expand Up @@ -163,7 +164,7 @@ function Logs({ logs, traceStartTime, open, onToggleOpen }) {
Logs.propTypes = {
open: PropTypes.bool,
onToggleOpen: PropTypes.func,
logs: PropTypes.array(
logs: PropTypes.arrayOf(
PropTypes.shape({
timestamp: PropTypes.number,
fields: PropTypes.array,
Expand Down
3 changes: 2 additions & 1 deletion src/components/TracePage/TraceTimelineViewer/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { Component, PropTypes } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import _ from 'lodash';
import {
onlyUpdateForKeys,
Expand Down
3 changes: 2 additions & 1 deletion src/components/TracePage/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import React, { Component, PropTypes } from 'react';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import { Sticky } from 'react-sticky';
Expand Down
2 changes: 1 addition & 1 deletion src/propTypes/dependencies.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import { PropTypes } from 'react';
import PropTypes from 'prop-types';

export const nodesPropTypes = PropTypes.arrayOf(
PropTypes.shape({
Expand Down
2 changes: 1 addition & 1 deletion src/propTypes/log.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import { PropTypes } from 'react';
import PropTypes from 'prop-types';

export default PropTypes.shape({
timestamp: PropTypes.number,
Expand Down
2 changes: 1 addition & 1 deletion src/propTypes/span.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import { PropTypes } from 'react';
import PropTypes from 'prop-types';

export default PropTypes.shape({
duration: PropTypes.number,
Expand Down
2 changes: 1 addition & 1 deletion src/propTypes/spanGraphTick.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import { PropTypes } from 'react';
import PropTypes from 'prop-types';

export default PropTypes.shape({
timestamp: PropTypes.number,
Expand Down
2 changes: 1 addition & 1 deletion src/propTypes/tag.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import { PropTypes } from 'react';
import PropTypes from 'prop-types';

export default PropTypes.shape({
key: PropTypes.string,
Expand Down
2 changes: 1 addition & 1 deletion src/propTypes/trace.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import { PropTypes } from 'react';
import PropTypes from 'prop-types';

import spanPropTypes from './span';

Expand Down
2 changes: 1 addition & 1 deletion src/propTypes/traceColumn.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import { PropTypes } from 'react';
import PropTypes from 'prop-types';

export default PropTypes.shape({
comparator: PropTypes.func.isRequired,
Expand Down
2 changes: 1 addition & 1 deletion src/propTypes/traceTableColumn.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

import { PropTypes } from 'react';
import PropTypes from 'prop-types';

export default PropTypes.shape({
timestamp: PropTypes.number,
Expand Down
Loading

0 comments on commit c30737e

Please sign in to comment.