react-vis
Advanced tools
Comparing version 1.1.1 to 1.2.0
@@ -130,3 +130,3 @@ 'use strict'; | ||
exports.AbstractSeries = _abstractSeries2.default; // Copyright (c) 2016 Uber Technologies, Inc. | ||
exports.AbstractSeries = _abstractSeries2.default; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -133,0 +133,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -15,3 +15,3 @@ 'use strict'; | ||
// Copyright (c) 2016 Uber Technologies, Inc. | ||
// Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -18,0 +18,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -22,3 +22,3 @@ 'use strict'; | ||
width: _react2.default.PropTypes.number | ||
}; // Copyright (c) 2016 Uber Technologies, Inc. | ||
}; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -25,0 +25,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -19,3 +19,3 @@ 'use strict'; | ||
orientation: _react2.default.PropTypes.oneOf(['vertical', 'horizontal']).isRequired | ||
}; // Copyright (c) 2016 Uber Technologies, Inc. | ||
}; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -22,0 +22,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -7,3 +7,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -10,0 +10,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -7,3 +7,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -10,0 +10,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -31,3 +31,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -34,0 +34,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -7,3 +7,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -10,0 +10,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -27,3 +27,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -30,0 +30,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -15,3 +15,3 @@ 'use strict'; | ||
// Copyright (c) 2016 Uber Technologies, Inc. | ||
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -36,2 +36,4 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy | ||
// Assuming that 16px = 1em | ||
var ADJUSTMENT_FOR_TEXT_SIZE = 16; | ||
var LEFT = _axisUtils.ORIENTATION.LEFT, | ||
@@ -42,3 +44,35 @@ RIGHT = _axisUtils.ORIENTATION.RIGHT, | ||
/** | ||
* Compute transformations, keyed by orientation | ||
* @param {number} width - width of axis | ||
* @param {number} height - height of axis | ||
* @returns {Object} Object of transformations, keyed by orientation | ||
*/ | ||
var transformation = function transformation(width, height) { | ||
var _ref; | ||
return _ref = {}, _defineProperty(_ref, LEFT, { | ||
x: ADJUSTMENT_FOR_TEXT_SIZE, | ||
y: 0, | ||
rotation: -90, | ||
textAnchor: 'end' | ||
}), _defineProperty(_ref, RIGHT, { | ||
x: ADJUSTMENT_FOR_TEXT_SIZE * -0.5, | ||
y: height, | ||
rotation: -90, | ||
textAnchor: 'start' | ||
}), _defineProperty(_ref, TOP, { | ||
x: 0, | ||
y: ADJUSTMENT_FOR_TEXT_SIZE, | ||
rotation: 0, | ||
textAnchor: 'start' | ||
}), _defineProperty(_ref, BOTTOM, { | ||
x: width, | ||
y: -6, | ||
rotation: 0, | ||
textAnchor: 'end' | ||
}), _ref; | ||
}; | ||
var propTypes = { | ||
@@ -51,37 +85,25 @@ width: _react2.default.PropTypes.number.isRequired, | ||
function AxisTitle(_ref) { | ||
var orientation = _ref.orientation, | ||
width = _ref.width, | ||
height = _ref.height, | ||
title = _ref.title; | ||
function AxisTitle(_ref2) { | ||
var orientation = _ref2.orientation, | ||
width = _ref2.width, | ||
height = _ref2.height, | ||
title = _ref2.title; | ||
var x = orientation === LEFT ? width : 0; | ||
var y = orientation === TOP ? height : 0; | ||
var style = void 0; | ||
if (orientation === LEFT) { | ||
style = { | ||
transform: 'translate(1em, 0) rotate(-90deg)', | ||
textAnchor: 'end' | ||
}; | ||
} else if (orientation === RIGHT) { | ||
style = { | ||
transform: 'translate(-0.5em, ' + height + 'px) rotate(-90deg)', | ||
textAnchor: 'start' | ||
}; | ||
} else if (orientation === BOTTOM) { | ||
style = { | ||
transform: 'translate(' + width + 'px, -6px)', | ||
textAnchor: 'end' | ||
}; | ||
} else { | ||
style = { | ||
transform: 'translate(0px, 1em)' | ||
}; | ||
} | ||
var outerGroupTranslateX = orientation === LEFT ? width : 0; | ||
var outerGroupTranslateY = orientation === TOP ? height : 0; | ||
var outerGroupTransform = 'translate(' + outerGroupTranslateX + ', ' + outerGroupTranslateY + ')'; | ||
var _transformation$orien = transformation(width, height)[orientation], | ||
x = _transformation$orien.x, | ||
y = _transformation$orien.y, | ||
rotation = _transformation$orien.rotation, | ||
textAnchor = _transformation$orien.textAnchor; | ||
var innerGroupTransform = 'translate(' + x + ', ' + y + ') rotate(' + rotation + ')'; | ||
return _react2.default.createElement( | ||
'g', | ||
{ transform: 'translate(' + x + ', ' + y + ')', className: 'rv-xy-plot__axis__title' }, | ||
{ transform: outerGroupTransform, className: 'rv-xy-plot__axis__title' }, | ||
_react2.default.createElement( | ||
'g', | ||
{ style: style }, | ||
{ style: { textAnchor: textAnchor }, transform: innerGroupTransform }, | ||
_react2.default.createElement( | ||
@@ -88,0 +110,0 @@ 'text', |
@@ -43,3 +43,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -46,0 +46,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -7,3 +7,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -10,0 +10,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -7,3 +7,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -10,0 +10,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -25,3 +25,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -28,0 +28,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -37,3 +37,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -40,0 +40,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -27,3 +27,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -30,0 +30,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -7,3 +7,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -10,0 +10,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -9,3 +9,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -34,2 +34,4 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy | ||
var _d3Voronoi = require('d3-voronoi'); | ||
var _pureRenderComponent = require('../../pure-render-component'); | ||
@@ -62,2 +64,3 @@ | ||
onNearestX: _react2.default.PropTypes.func, | ||
onNearestXY: _react2.default.PropTypes.func, | ||
animation: _animationUtils.AnimationPropType | ||
@@ -262,22 +265,27 @@ }); | ||
}, { | ||
key: '_getXCoordinateInContainer', | ||
value: function _getXCoordinateInContainer(event) { | ||
var _props$marginLeft = this.props.marginLeft, | ||
marginLeft = _props$marginLeft === undefined ? 0 : _props$marginLeft; | ||
var clientX = event.nativeEvent.clientX, | ||
key: '_getXYCoordinateInContainer', | ||
value: function _getXYCoordinateInContainer(event) { | ||
var _props4 = this.props, | ||
_props4$marginTop = _props4.marginTop, | ||
marginTop = _props4$marginTop === undefined ? 0 : _props4$marginTop, | ||
_props4$marginLeft = _props4.marginLeft, | ||
marginLeft = _props4$marginLeft === undefined ? 0 : _props4$marginLeft; | ||
var _event$nativeEvent = event.nativeEvent, | ||
clientX = _event$nativeEvent.clientX, | ||
clientY = _event$nativeEvent.clientY, | ||
currentTarget = event.currentTarget; | ||
var rect = currentTarget.getBoundingClientRect(); | ||
return clientX - rect.left - currentTarget.clientLeft - marginLeft; | ||
return { | ||
x: clientX - rect.left - currentTarget.clientLeft - marginLeft, | ||
y: clientY - rect.top - currentTarget.clientTop - marginTop | ||
}; | ||
} | ||
}, { | ||
key: 'onParentMouseMove', | ||
value: function onParentMouseMove(event) { | ||
var _props4 = this.props, | ||
onNearestX = _props4.onNearestX, | ||
data = _props4.data; | ||
key: '_handleNearestX', | ||
value: function _handleNearestX(event) { | ||
var _props5 = this.props, | ||
onNearestX = _props5.onNearestX, | ||
data = _props5.data; | ||
if (!onNearestX || !data) { | ||
return; | ||
} | ||
var minDistance = Number.POSITIVE_INFINITY; | ||
@@ -287,3 +295,3 @@ var value = null; | ||
var coordinate = this._getXCoordinateInContainer(event); | ||
var coordinate = this._getXYCoordinateInContainer(event); | ||
var xScaleFn = this._getAttributeFunctor('x'); | ||
@@ -293,3 +301,3 @@ | ||
var currentCoordinate = xScaleFn(item); | ||
var newDistance = Math.abs(coordinate - currentCoordinate); | ||
var newDistance = Math.abs(coordinate.x - currentCoordinate); | ||
if (newDistance < minDistance) { | ||
@@ -310,2 +318,47 @@ minDistance = newDistance; | ||
} | ||
}, { | ||
key: '_handleNearestXY', | ||
value: function _handleNearestXY(event) { | ||
var _props6 = this.props, | ||
onNearestXY = _props6.onNearestXY, | ||
data = _props6.data; | ||
var coordinate = this._getXYCoordinateInContainer(event); | ||
var xScaleFn = this._getAttributeFunctor('x'); | ||
var yScaleFn = this._getAttributeFunctor('y'); | ||
// Create a voronoi with each node center points | ||
var voronoiInstance = (0, _d3Voronoi.voronoi)().x(xScaleFn).y(yScaleFn); | ||
var foundPoint = voronoiInstance(data).find(coordinate.x, coordinate.y); | ||
var value = foundPoint.data; | ||
if (!value) { | ||
return; | ||
} | ||
onNearestXY(value, { | ||
innerX: foundPoint.x, | ||
innerY: foundPoint.y, | ||
index: foundPoint.index, | ||
event: event.nativeEvent | ||
}); | ||
} | ||
}, { | ||
key: 'onParentMouseMove', | ||
value: function onParentMouseMove(event) { | ||
var _props7 = this.props, | ||
onNearestX = _props7.onNearestX, | ||
onNearestXY = _props7.onNearestXY, | ||
data = _props7.data; | ||
if (!onNearestX && !onNearestXY || !data) { | ||
return; | ||
} | ||
if (onNearestXY) { | ||
this._handleNearestXY(event); | ||
} else { | ||
this._handleNearestX(event); | ||
} | ||
} | ||
}], [{ | ||
@@ -312,0 +365,0 @@ key: 'getParentConfig', |
@@ -39,3 +39,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -42,0 +42,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -33,3 +33,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -36,0 +36,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -31,3 +31,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -34,0 +34,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -29,3 +29,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -32,0 +32,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -29,3 +29,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -32,0 +32,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -31,3 +31,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -34,0 +34,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -9,3 +9,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -12,0 +12,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -33,3 +33,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -55,2 +55,3 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy | ||
var predefinedClassName = 'rv-xy-plot__series rv-xy-plot__series--mark'; | ||
var DEFAULT_STROKE_WIDTH = 1; | ||
@@ -76,3 +77,4 @@ var MarkSeries = function (_AbstractSeries) { | ||
marginLeft = _props.marginLeft, | ||
marginTop = _props.marginTop; | ||
marginTop = _props.marginTop, | ||
strokeWidth = _props.strokeWidth; | ||
@@ -110,3 +112,4 @@ if (!data) { | ||
stroke: strokeFunctor && strokeFunctor(d), | ||
fill: fillFunctor && fillFunctor(d) | ||
fill: fillFunctor && fillFunctor(d), | ||
strokeWidth: strokeWidth || DEFAULT_STROKE_WIDTH | ||
}, | ||
@@ -134,3 +137,5 @@ key: i, | ||
MarkSeries.displayName = 'MarkSeries'; | ||
MarkSeries.propTypes = _extends({}, _abstractSeries2.default.propTypes, { | ||
strokeWidth: _react.PropTypes.number | ||
}); | ||
exports.default = MarkSeries; |
@@ -33,3 +33,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -36,0 +36,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -29,3 +29,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -32,0 +32,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -29,3 +29,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -32,0 +32,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -7,3 +7,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -10,0 +10,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -37,3 +37,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -40,0 +40,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -23,3 +23,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -26,0 +26,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -11,3 +11,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -38,4 +38,2 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy | ||
var d3Shape = _interopRequireWildcard(_d3Shape); | ||
var _animation = require('../animation'); | ||
@@ -53,4 +51,2 @@ | ||
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
@@ -241,3 +237,3 @@ | ||
} | ||
return d3Shape.arc().outerRadius(radiusFunctor).innerRadius(innerRadiusFunctor); | ||
return (0, _d3Shape.arc)().outerRadius(radiusFunctor).innerRadius(innerRadiusFunctor); | ||
} | ||
@@ -396,3 +392,3 @@ | ||
var pie = d3Shape.pie().sort(null).value(function (d) { | ||
var pie = (0, _d3Shape.pie)().sort(null).value(function (d) { | ||
return d.angle; | ||
@@ -399,0 +395,0 @@ }); |
@@ -6,3 +6,3 @@ 'use strict'; | ||
}); | ||
// Copyright (c) 2016 Uber Technologies, Inc. | ||
// Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -9,0 +9,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -9,3 +9,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -12,0 +12,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -29,3 +29,3 @@ 'use strict'; | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -32,0 +32,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -21,3 +21,3 @@ 'use strict'; | ||
*/ | ||
// Copyright (c) 2016 Uber Technologies, Inc. | ||
// Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -24,0 +24,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -8,3 +8,3 @@ 'use strict'; | ||
exports.getTickValues = getTickValues; | ||
// Copyright (c) 2016 Uber Technologies, Inc. | ||
// Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -11,0 +11,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -8,3 +8,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -11,0 +11,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -9,3 +9,3 @@ "use strict"; | ||
exports.addValueToArray = addValueToArray; | ||
// Copyright (c) 2016 Uber Technologies, Inc. | ||
// Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -12,0 +12,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -8,3 +8,3 @@ 'use strict'; | ||
var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }(); // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }(); // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -11,0 +11,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -29,12 +29,6 @@ 'use strict'; | ||
var d3Scale = _interopRequireWildcard(_d3Scale); | ||
var _d3Array = require('d3-array'); | ||
var d3Array = _interopRequireWildcard(_d3Array); | ||
var _d3Collection = require('d3-collection'); | ||
var d3Collection = _interopRequireWildcard(_d3Collection); | ||
var _d3Color = require('d3-color'); | ||
@@ -52,7 +46,5 @@ | ||
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } | ||
function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } } | ||
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; } // Copyright (c) 2016 Uber Technologies, Inc. | ||
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; } // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -133,3 +125,3 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy | ||
*/ | ||
var SCALE_FUNCTIONS = (_SCALE_FUNCTIONS = {}, _defineProperty(_SCALE_FUNCTIONS, LINEAR_SCALE_TYPE, d3Scale.scaleLinear), _defineProperty(_SCALE_FUNCTIONS, ORDINAL_SCALE_TYPE, d3Scale.scalePoint), _defineProperty(_SCALE_FUNCTIONS, CATEGORY_SCALE_TYPE, d3Scale.scaleOrdinal), _defineProperty(_SCALE_FUNCTIONS, LITERAL_SCALE_TYPE, literalScale), _defineProperty(_SCALE_FUNCTIONS, LOG_SCALE_TYPE, d3Scale.scaleLog), _defineProperty(_SCALE_FUNCTIONS, TIME_SCALE_TYPE, d3Scale.scaleTime), _defineProperty(_SCALE_FUNCTIONS, TIME_UTC_SCALE_TYPE, d3Scale.scaleUtc), _SCALE_FUNCTIONS); | ||
var SCALE_FUNCTIONS = (_SCALE_FUNCTIONS = {}, _defineProperty(_SCALE_FUNCTIONS, LINEAR_SCALE_TYPE, _d3Scale.scaleLinear), _defineProperty(_SCALE_FUNCTIONS, ORDINAL_SCALE_TYPE, _d3Scale.scalePoint), _defineProperty(_SCALE_FUNCTIONS, CATEGORY_SCALE_TYPE, _d3Scale.scaleOrdinal), _defineProperty(_SCALE_FUNCTIONS, LITERAL_SCALE_TYPE, literalScale), _defineProperty(_SCALE_FUNCTIONS, LOG_SCALE_TYPE, _d3Scale.scaleLog), _defineProperty(_SCALE_FUNCTIONS, TIME_SCALE_TYPE, _d3Scale.scaleTime), _defineProperty(_SCALE_FUNCTIONS, TIME_UTC_SCALE_TYPE, _d3Scale.scaleUtc), _SCALE_FUNCTIONS); | ||
/** | ||
@@ -224,5 +216,5 @@ * Find the smallest distance between the values on a given scale and return | ||
if (type !== ORDINAL_SCALE_TYPE && type !== CATEGORY_SCALE_TYPE) { | ||
domain = d3Array.extent(values); | ||
domain = (0, _d3Array.extent)(values); | ||
} else { | ||
domain = d3Collection.set(values).values(); | ||
domain = (0, _d3Collection.set)(values).values(); | ||
} | ||
@@ -229,0 +221,0 @@ return domain; |
@@ -8,3 +8,3 @@ 'use strict'; | ||
var _extends = Object.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; }; // Copyright (c) 2016 Uber Technologies, Inc. | ||
var _extends = Object.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; }; // Copyright (c) 2016 - 2017 Uber Technologies, Inc. | ||
// | ||
@@ -11,0 +11,0 @@ // Permission is hereby granted, free of charge, to any person obtaining a copy |
{ | ||
"name": "react-vis", | ||
"version": "1.1.1", | ||
"version": "1.2.0", | ||
"license": "MIT", | ||
@@ -5,0 +5,0 @@ "author": "Visualization Team <visualization@uber.com>", |
317561
6107