-
Notifications
You must be signed in to change notification settings - Fork 204
/
Copy pathreact-d3-components.js
516 lines (410 loc) · 172 KB
/
react-d3-components.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory(require("d3"), require("React"), require("ReactDOM"));
else if(typeof define === 'function' && define.amd)
define(["d3", "React", "ReactDOM"], factory);
else if(typeof exports === 'object')
exports["ReactD3"] = factory(require("d3"), require("React"), require("ReactDOM"));
else
root["ReactD3"] = factory(root["d3"], root["React"], root["ReactDOM"]);
})(window, function(__WEBPACK_EXTERNAL_MODULE_d3__, __WEBPACK_EXTERNAL_MODULE_react__, __WEBPACK_EXTERNAL_MODULE_react_dom__) {
return /******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId]) {
/******/ return installedModules[moduleId].exports;
/******/ }
/******/ // Create a new module (and put it into the cache)
/******/ var module = installedModules[moduleId] = {
/******/ i: moduleId,
/******/ l: false,
/******/ exports: {}
/******/ };
/******/
/******/ // Execute the module function
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ // Flag the module as loaded
/******/ module.l = true;
/******/
/******/ // Return the exports of the module
/******/ return module.exports;
/******/ }
/******/
/******/
/******/ // expose the modules object (__webpack_modules__)
/******/ __webpack_require__.m = modules;
/******/
/******/ // expose the module cache
/******/ __webpack_require__.c = installedModules;
/******/
/******/ // define getter function for harmony exports
/******/ __webpack_require__.d = function(exports, name, getter) {
/******/ if(!__webpack_require__.o(exports, name)) {
/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
/******/ }
/******/ };
/******/
/******/ // define __esModule on exports
/******/ __webpack_require__.r = function(exports) {
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ }
/******/ Object.defineProperty(exports, '__esModule', { value: true });
/******/ };
/******/
/******/ // create a fake namespace object
/******/ // mode & 1: value is a module id, require it
/******/ // mode & 2: merge all properties of value into the ns
/******/ // mode & 4: return value when already ns object
/******/ // mode & 8|1: behave like require
/******/ __webpack_require__.t = function(value, mode) {
/******/ if(mode & 1) value = __webpack_require__(value);
/******/ if(mode & 8) return value;
/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
/******/ var ns = Object.create(null);
/******/ __webpack_require__.r(ns);
/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
/******/ return ns;
/******/ };
/******/
/******/ // getDefaultExport function for compatibility with non-harmony modules
/******/ __webpack_require__.n = function(module) {
/******/ var getter = module && module.__esModule ?
/******/ function getDefault() { return module['default']; } :
/******/ function getModuleExports() { return module; };
/******/ __webpack_require__.d(getter, 'a', getter);
/******/ return getter;
/******/ };
/******/
/******/ // Object.prototype.hasOwnProperty.call
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "";
/******/
/******/
/******/ // Load entry module and return exports
/******/ return __webpack_require__(__webpack_require__.s = "./src/index.jsx");
/******/ })
/************************************************************************/
/******/ ({
/***/ "./node_modules/create-react-class/factory.js":
/*!****************************************************!*\
!*** ./node_modules/create-react-class/factory.js ***!
\****************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n */\n\n\n\nvar _assign = __webpack_require__(/*! object-assign */ \"./node_modules/object-assign/index.js\");\n\nvar emptyObject = __webpack_require__(/*! fbjs/lib/emptyObject */ \"./node_modules/fbjs/lib/emptyObject.js\");\nvar _invariant = __webpack_require__(/*! fbjs/lib/invariant */ \"./node_modules/fbjs/lib/invariant.js\");\n\nif (true) {\n var warning = __webpack_require__(/*! fbjs/lib/warning */ \"./node_modules/fbjs/lib/warning.js\");\n}\n\nvar MIXINS_KEY = 'mixins';\n\n// Helper function to allow the creation of anonymous functions which do not\n// have .name set to the name of the variable being assigned to.\nfunction identity(fn) {\n return fn;\n}\n\nvar ReactPropTypeLocationNames;\nif (true) {\n ReactPropTypeLocationNames = {\n prop: 'prop',\n context: 'context',\n childContext: 'child context'\n };\n} else {}\n\nfunction factory(ReactComponent, isValidElement, ReactNoopUpdateQueue) {\n /**\n * Policies that describe methods in `ReactClassInterface`.\n */\n\n var injectedMixins = [];\n\n /**\n * Composite components are higher-level components that compose other composite\n * or host components.\n *\n * To create a new type of `ReactClass`, pass a specification of\n * your new class to `React.createClass`. The only requirement of your class\n * specification is that you implement a `render` method.\n *\n * var MyComponent = React.createClass({\n * render: function() {\n * return <div>Hello World</div>;\n * }\n * });\n *\n * The class specification supports a specific protocol of methods that have\n * special meaning (e.g. `render`). See `ReactClassInterface` for\n * more the comprehensive protocol. Any other properties and methods in the\n * class specification will be available on the prototype.\n *\n * @interface ReactClassInterface\n * @internal\n */\n var ReactClassInterface = {\n /**\n * An array of Mixin objects to include when defining your component.\n *\n * @type {array}\n * @optional\n */\n mixins: 'DEFINE_MANY',\n\n /**\n * An object containing properties and methods that should be defined on\n * the component's constructor instead of its prototype (static methods).\n *\n * @type {object}\n * @optional\n */\n statics: 'DEFINE_MANY',\n\n /**\n * Definition of prop types for this component.\n *\n * @type {object}\n * @optional\n */\n propTypes: 'DEFINE_MANY',\n\n /**\n * Definition of context types for this component.\n *\n * @type {object}\n * @optional\n */\n contextTypes: 'DEFINE_MANY',\n\n /**\n * Definition of context types this component sets for its children.\n *\n * @type {object}\n * @optional\n */\n childContextTypes: 'DEFINE_MANY',\n\n // ==== Definition methods ====\n\n /**\n * Invoked when the component is mounted. Values in the mapping will be set on\n * `this.props` if that prop is not specified (i.e. using an `in` check).\n *\n * This method is invoked before `getInitialState` and therefore cannot rely\n * on `this.state` or use `this.setState`.\n *\n * @return {object}\n * @optional\n */\n getDefaultProps: 'DEFINE_MANY_MERGED',\n\n /**\n * Invoked once before the component is mounted. The return value will be used\n * as the initial value of `this.state`.\n *\n * getInitialState: function() {\n * return {\n * isOn: false,\n * fooBaz: new BazFoo()\n * }\n * }\n *\n * @return {object}\n * @optional\n */\n getInitialState: 'DEFINE_MANY_MERGED',\n\n /**\n * @return {object}\n * @optional\n */\n getChildContext: 'DEFINE_MANY_MERGED',\n\n /**\n * Uses props from `this.props` and state from `this.state` to render the\n * structure of the component.\n *\n * No guarantees are made about when or how often this method is invoked, so\n * it must not have side effects.\n *\n * render: function() {\n * var name = this.props.name;\n * return <div>Hello, {name}!</div>;\n * }\n *\n * @return {ReactComponent}\n * @required\n */\n render: 'DEFINE_ONCE',\n\n // ==== Delegate methods ====\n\n /**\n * Invoked when the component is initially created and about to be mounted.\n * This may have side effects, but any external subscriptions or data created\n * by this method must be cleaned up in `componentWillUnmount`.\n *\n * @optional\n */\n componentWillMount: 'DEFINE_MANY',\n\n /**\n * Invoked when the component has been mounted and has a DOM representation.\n * However, there is no guarantee that the DOM node is in the document.\n *\n * Use this as an opportunity to operate on the DOM when the component has\n * been mounted (initialized and rendered) for the first time.\n *\n * @param {DOMElement} rootNode DOM element representing the component.\n * @optional\n */\n componentDidMount: 'DEFINE_MANY',\n\n /**\n * Invoked before the component receives new props.\n *\n * Use this as an opportunity to react to a prop transition by updating the\n * state using `this.setState`. Current props are accessed via `this.props`.\n *\n * componentWillReceiveProps: function(nextProps, nextContext) {\n * this.setState({\n * likesIncreasing: nextProps.likeCount > this.props.likeCount\n * });\n * }\n *\n * NOTE: There is no equivalent `componentWillReceiveState`. An incoming prop\n * transition may cause a state change, but the opposite is not true. If you\n * need it, you are probably looking for `componentWillUpdate`.\n *\n * @param {object} nextProps\n * @optional\n */\n componentWillReceiveProps: 'DEFINE_MANY',\n\n /**\n * Invoked while deciding if the component should be updated as a result of\n * receiving new props, state and/or context.\n *\n * Use this as an opportunity to `return false` when you're certain that the\n * transition to the new props/state/context will not require a component\n * update.\n *\n * shouldComponentUpdate: function(nextProps, nextState, nextContext) {\n * return !equal(nextProps, this.props) ||\n * !equal(nextState, this.state) ||\n * !equal(nextContext, this.context);\n * }\n *\n * @param {object} nextProps\n * @param {?object} nextState\n * @param {?object} nextContext\n * @return {boolean} True if the component should update.\n * @optional\n */\n shouldComponentUpdate: 'DEFINE_ONCE',\n\n /**\n * Invoked when the component is about to update due to a transition from\n * `this.props`, `this.state` and `this.context` to `nextProps`, `nextState`\n * and `nextContext`.\n *\n * Use this as an opportunity to perform preparation before an update occurs.\n *\n * NOTE: You **cannot** use `this.setState()` in this method.\n *\n * @param {object} nextProps\n * @param {?object} nextState\n * @param {?object} nextContext\n * @param {ReactReconcileTransaction} transaction\n * @optional\n */\n componentWillUpdate: 'DEFINE_MANY',\n\n /**\n * Invoked when the component's DOM representation has been updated.\n *\n * Use this as an opportunity to operate on the DOM when the component has\n * been updated.\n *\n * @param {object} prevProps\n * @param {?object} prevState\n * @param {?object} prevContext\n * @param {DOMElement} rootNode DOM element representing the component.\n * @optional\n */\n componentDidUpdate: 'DEFINE_MANY',\n\n /**\n * Invoked when the component is about to be removed from its parent and have\n * its DOM representation destroyed.\n *\n * Use this as an opportunity to deallocate any external resources.\n *\n * NOTE: There is no `componentDidUnmount` since your component will have been\n * destroyed by that point.\n *\n * @optional\n */\n componentWillUnmount: 'DEFINE_MANY',\n\n /**\n * Replacement for (deprecated) `componentWillMount`.\n *\n * @optional\n */\n UNSAFE_componentWillMount: 'DEFINE_MANY',\n\n /**\n * Replacement for (deprecated) `componentWillReceiveProps`.\n *\n * @optional\n */\n UNSAFE_componentWillReceiveProps: 'DEFINE_MANY',\n\n /**\n * Replacement for (deprecated) `componentWillUpdate`.\n *\n * @optional\n */\n UNSAFE_componentWillUpdate: 'DEFINE_MANY',\n\n // ==== Advanced methods ====\n\n /**\n * Updates the component's currently mounted DOM representation.\n *\n * By default, this implements React's rendering and reconciliation algorithm.\n * Sophisticated clients may wish to override this.\n *\n * @param {ReactReconcileTransaction} transaction\n * @internal\n * @overridable\n */\n updateComponent: 'OVERRIDE_BASE'\n };\n\n /**\n * Similar to ReactClassInterface but for static methods.\n */\n var ReactClassStaticInterface = {\n /**\n * This method is invoked after a component is instantiated and when it\n * receives new props. Return an object to update state in response to\n * prop changes. Return null to indicate no change to state.\n *\n * If an object is returned, its keys will be merged into the existing state.\n *\n * @return {object || null}\n * @optional\n */\n getDerivedStateFromProps: 'DEFINE_MANY_MERGED'\n };\n\n /**\n * Mapping from class specification keys to special processing functions.\n *\n * Although these are declared like instance properties in the specification\n * when defining classes using `React.createClass`, they are actually static\n * and are accessible on the constructor instead of the prototype. Despite\n * being static, they must be defined outside of the \"statics\" key under\n * which all other static methods are defined.\n */\n var RESERVED_SPEC_KEYS = {\n displayName: function(Constructor, displayName) {\n Constructor.displayName = displayName;\n },\n mixins: function(Constructor, mixins) {\n if (mixins) {\n for (var i = 0; i < mixins.length; i++) {\n mixSpecIntoComponent(Constructor, mixins[i]);\n }\n }\n },\n childContextTypes: function(Constructor, childContextTypes) {\n if (true) {\n validateTypeDef(Constructor, childContextTypes, 'childContext');\n }\n Constructor.childContextTypes = _assign(\n {},\n Constructor.childContextTypes,\n childContextTypes\n );\n },\n contextTypes: function(Constructor, contextTypes) {\n if (true) {\n validateTypeDef(Constructor, contextTypes, 'context');\n }\n Constructor.contextTypes = _assign(\n {},\n Constructor.contextTypes,\n contextTypes\n );\n },\n /**\n * Special case getDefaultProps which should move into statics but requires\n * automatic merging.\n */\n getDefaultProps: function(Constructor, getDefaultProps) {\n if (Constructor.getDefaultProps) {\n Constructor.getDefaultProps = createMergedResultFunction(\n Constructor.getDefaultProps,\n getDefaultProps\n );\n } else {\n Constructor.getDefaultProps = getDefaultProps;\n }\n },\n propTypes: function(Constructor, propTypes) {\n if (true) {\n validateTypeDef(Constructor, propTypes, 'prop');\n }\n Constructor.propTypes = _assign({}, Constructor.propTypes, propTypes);\n },\n statics: function(Constructor, statics) {\n mixStaticSpecIntoComponent(Constructor, statics);\n },\n autobind: function() {}\n };\n\n function validateTypeDef(Constructor, typeDef, location) {\n for (var propName in typeDef) {\n if (typeDef.hasOwnProperty(propName)) {\n // use a warning instead of an _invariant so components\n // don't show up in prod but only in __DEV__\n if (true) {\n warning(\n typeof typeDef[propName] === 'function',\n '%s: %s type `%s` is invalid; it must be a function, usually from ' +\n 'React.PropTypes.',\n Constructor.displayName || 'ReactClass',\n ReactPropTypeLocationNames[location],\n propName\n );\n }\n }\n }\n }\n\n function validateMethodOverride(isAlreadyDefined, name) {\n var specPolicy = ReactClassInterface.hasOwnProperty(name)\n ? ReactClassInterface[name]\n : null;\n\n // Disallow overriding of base class methods unless explicitly allowed.\n if (ReactClassMixin.hasOwnProperty(name)) {\n _invariant(\n specPolicy === 'OVERRIDE_BASE',\n 'ReactClassInterface: You are attempting to override ' +\n '`%s` from your class specification. Ensure that your method names ' +\n 'do not overlap with React methods.',\n name\n );\n }\n\n // Disallow defining methods more than once unless explicitly allowed.\n if (isAlreadyDefined) {\n _invariant(\n specPolicy === 'DEFINE_MANY' || specPolicy === 'DEFINE_MANY_MERGED',\n 'ReactClassInterface: You are attempting to define ' +\n '`%s` on your component more than once. This conflict may be due ' +\n 'to a mixin.',\n name\n );\n }\n }\n\n /**\n * Mixin helper which handles policy validation and reserved\n * specification keys when building React classes.\n */\n function mixSpecIntoComponent(Constructor, spec) {\n if (!spec) {\n if (true) {\n var typeofSpec = typeof spec;\n var isMixinValid = typeofSpec === 'object' && spec !== null;\n\n if (true) {\n warning(\n isMixinValid,\n \"%s: You're attempting to include a mixin that is either null \" +\n 'or not an object. Check the mixins included by the component, ' +\n 'as well as any mixins they include themselves. ' +\n 'Expected object but got %s.',\n Constructor.displayName || 'ReactClass',\n spec === null ? null : typeofSpec\n );\n }\n }\n\n return;\n }\n\n _invariant(\n typeof spec !== 'function',\n \"ReactClass: You're attempting to \" +\n 'use a component class or function as a mixin. Instead, just use a ' +\n 'regular object.'\n );\n _invariant(\n !isValidElement(spec),\n \"ReactClass: You're attempting to \" +\n 'use a component as a mixin. Instead, just use a regular object.'\n );\n\n var proto = Constructor.prototype;\n var autoBindPairs = proto.__reactAutoBindPairs;\n\n // By handling mixins before any other properties, we ensure the same\n // chaining order is applied to methods with DEFINE_MANY policy, whether\n // mixins are listed before or after these methods in the spec.\n if (spec.hasOwnProperty(MIXINS_KEY)) {\n RESERVED_SPEC_KEYS.mixins(Constructor, spec.mixins);\n }\n\n for (var name in spec) {\n if (!spec.hasOwnProperty(name)) {\n continue;\n }\n\n if (name === MIXINS_KEY) {\n // We have already handled mixins in a special case above.\n continue;\n }\n\n var property = spec[name];\n var isAlreadyDefined = proto.hasOwnProperty(name);\n validateMethodOverride(isAlreadyDefined, name);\n\n if (RESERVED_SPEC_KEYS.hasOwnProperty(name)) {\n RESERVED_SPEC_KEYS[name](Constructor, property);\n } else {\n // Setup methods on prototype:\n // The following member methods should not be automatically bound:\n // 1. Expected ReactClass methods (in the \"interface\").\n // 2. Overridden methods (that were mixed in).\n var isReactClassMethod = ReactClassInterface.hasOwnProperty(name);\n var isFunction = typeof property === 'function';\n var shouldAutoBind =\n isFunction &&\n !isReactClassMethod &&\n !isAlreadyDefined &&\n spec.autobind !== false;\n\n if (shouldAutoBind) {\n autoBindPairs.push(name, property);\n proto[name] = property;\n } else {\n if (isAlreadyDefined) {\n var specPolicy = ReactClassInterface[name];\n\n // These cases should already be caught by validateMethodOverride.\n _invariant(\n isReactClassMethod &&\n (specPolicy === 'DEFINE_MANY_MERGED' ||\n specPolicy === 'DEFINE_MANY'),\n 'ReactClass: Unexpected spec policy %s for key %s ' +\n 'when mixing in component specs.',\n specPolicy,\n name\n );\n\n // For methods which are defined more than once, call the existing\n // methods before calling the new property, merging if appropriate.\n if (specPolicy === 'DEFINE_MANY_MERGED') {\n proto[name] = createMergedResultFunction(proto[name], property);\n } else if (specPolicy === 'DEFINE_MANY') {\n proto[name] = createChainedFunction(proto[name], property);\n }\n } else {\n proto[name] = property;\n if (true) {\n // Add verbose displayName to the function, which helps when looking\n // at profiling tools.\n if (typeof property === 'function' && spec.displayName) {\n proto[name].displayName = spec.displayName + '_' + name;\n }\n }\n }\n }\n }\n }\n }\n\n function mixStaticSpecIntoComponent(Constructor, statics) {\n if (!statics) {\n return;\n }\n\n for (var name in statics) {\n var property = statics[name];\n if (!statics.hasOwnProperty(name)) {\n continue;\n }\n\n var isReserved = name in RESERVED_SPEC_KEYS;\n _invariant(\n !isReserved,\n 'ReactClass: You are attempting to define a reserved ' +\n 'property, `%s`, that shouldn\\'t be on the \"statics\" key. Define it ' +\n 'as an instance property instead; it will still be accessible on the ' +\n 'constructor.',\n name\n );\n\n var isAlreadyDefined = name in Constructor;\n if (isAlreadyDefined) {\n var specPolicy = ReactClassStaticInterface.hasOwnProperty(name)\n ? ReactClassStaticInterface[name]\n : null;\n\n _invariant(\n specPolicy === 'DEFINE_MANY_MERGED',\n 'ReactClass: You are attempting to define ' +\n '`%s` on your component more than once. This conflict may be ' +\n 'due to a mixin.',\n name\n );\n\n Constructor[name] = createMergedResultFunction(Constructor[name], property);\n\n return;\n }\n\n Constructor[name] = property;\n }\n }\n\n /**\n * Merge two objects, but throw if both contain the same key.\n *\n * @param {object} one The first object, which is mutated.\n * @param {object} two The second object\n * @return {object} one after it has been mutated to contain everything in two.\n */\n function mergeIntoWithNoDuplicateKeys(one, two) {\n _invariant(\n one && two && typeof one === 'object' && typeof two === 'object',\n 'mergeIntoWithNoDuplicateKeys(): Cannot merge non-objects.'\n );\n\n for (var key in two) {\n if (two.hasOwnProperty(key)) {\n _invariant(\n one[key] === undefined,\n 'mergeIntoWithNoDuplicateKeys(): ' +\n 'Tried to merge two objects with the same key: `%s`. This conflict ' +\n 'may be due to a mixin; in particular, this may be caused by two ' +\n 'getInitialState() or getDefaultProps() methods returning objects ' +\n 'with clashing keys.',\n key\n );\n one[key] = two[key];\n }\n }\n return one;\n }\n\n /**\n * Creates a function that invokes two functions and merges their return values.\n *\n * @param {function} one Function to invoke first.\n * @param {function} two Function to invoke second.\n * @return {function} Function that invokes the two argument functions.\n * @private\n */\n function createMergedResultFunction(one, two) {\n return function mergedResult() {\n var a = one.apply(this, arguments);\n var b = two.apply(this, arguments);\n if (a == null) {\n return b;\n } else if (b == null) {\n return a;\n }\n var c = {};\n mergeIntoWithNoDuplicateKeys(c, a);\n mergeIntoWithNoDuplicateKeys(c, b);\n return c;\n };\n }\n\n /**\n * Creates a function that invokes two functions and ignores their return vales.\n *\n * @param {function} one Function to invoke first.\n * @param {function} two Function to invoke second.\n * @return {function} Function that invokes the two argument functions.\n * @private\n */\n function createChainedFunction(one, two) {\n return function chainedFunction() {\n one.apply(this, arguments);\n two.apply(this, arguments);\n };\n }\n\n /**\n * Binds a method to the component.\n *\n * @param {object} component Component whose method is going to be bound.\n * @param {function} method Method to be bound.\n * @return {function} The bound method.\n */\n function bindAutoBindMethod(component, method) {\n var boundMethod = method.bind(component);\n if (true) {\n boundMethod.__reactBoundContext = component;\n boundMethod.__reactBoundMethod = method;\n boundMethod.__reactBoundArguments = null;\n var componentName = component.constructor.displayName;\n var _bind = boundMethod.bind;\n boundMethod.bind = function(newThis) {\n for (\n var _len = arguments.length,\n args = Array(_len > 1 ? _len - 1 : 0),\n _key = 1;\n _key < _len;\n _key++\n ) {\n args[_key - 1] = arguments[_key];\n }\n\n // User is trying to bind() an autobound method; we effectively will\n // ignore the value of \"this\" that the user is trying to use, so\n // let's warn.\n if (newThis !== component && newThis !== null) {\n if (true) {\n warning(\n false,\n 'bind(): React component methods may only be bound to the ' +\n 'component instance. See %s',\n componentName\n );\n }\n } else if (!args.length) {\n if (true) {\n warning(\n false,\n 'bind(): You are binding a component method to the component. ' +\n 'React does this for you automatically in a high-performance ' +\n 'way, so you can safely remove this call. See %s',\n componentName\n );\n }\n return boundMethod;\n }\n var reboundMethod = _bind.apply(boundMethod, arguments);\n reboundMethod.__reactBoundContext = component;\n reboundMethod.__reactBoundMethod = method;\n reboundMethod.__reactBoundArguments = args;\n return reboundMethod;\n };\n }\n return boundMethod;\n }\n\n /**\n * Binds all auto-bound methods in a component.\n *\n * @param {object} component Component whose method is going to be bound.\n */\n function bindAutoBindMethods(component) {\n var pairs = component.__reactAutoBindPairs;\n for (var i = 0; i < pairs.length; i += 2) {\n var autoBindKey = pairs[i];\n var method = pairs[i + 1];\n component[autoBindKey] = bindAutoBindMethod(component, method);\n }\n }\n\n var IsMountedPreMixin = {\n componentDidMount: function() {\n this.__isMounted = true;\n }\n };\n\n var IsMountedPostMixin = {\n componentWillUnmount: function() {\n this.__isMounted = false;\n }\n };\n\n /**\n * Add more to the ReactClass base class. These are all legacy features and\n * therefore not already part of the modern ReactComponent.\n */\n var ReactClassMixin = {\n /**\n * TODO: This will be deprecated because state should always keep a consistent\n * type signature and the only use case for this, is to avoid that.\n */\n replaceState: function(newState, callback) {\n this.updater.enqueueReplaceState(this, newState, callback);\n },\n\n /**\n * Checks whether or not this composite component is mounted.\n * @return {boolean} True if mounted, false otherwise.\n * @protected\n * @final\n */\n isMounted: function() {\n if (true) {\n warning(\n this.__didWarnIsMounted,\n '%s: isMounted is deprecated. Instead, make sure to clean up ' +\n 'subscriptions and pending requests in componentWillUnmount to ' +\n 'prevent memory leaks.',\n (this.constructor && this.constructor.displayName) ||\n this.name ||\n 'Component'\n );\n this.__didWarnIsMounted = true;\n }\n return !!this.__isMounted;\n }\n };\n\n var ReactClassComponent = function() {};\n _assign(\n ReactClassComponent.prototype,\n ReactComponent.prototype,\n ReactClassMixin\n );\n\n /**\n * Creates a composite component class given a class specification.\n * See https://facebook.github.io/react/docs/top-level-api.html#react.createclass\n *\n * @param {object} spec Class specification (which must define `render`).\n * @return {function} Component constructor function.\n * @public\n */\n function createClass(spec) {\n // To keep our warnings more understandable, we'll use a little hack here to\n // ensure that Constructor.name !== 'Constructor'. This makes sure we don't\n // unnecessarily identify a class without displayName as 'Constructor'.\n var Constructor = identity(function(props, context, updater) {\n // This constructor gets overridden by mocks. The argument is used\n // by mocks to assert on what gets mounted.\n\n if (true) {\n warning(\n this instanceof Constructor,\n 'Something is calling a React component directly. Use a factory or ' +\n 'JSX instead. See: https://fb.me/react-legacyfactory'\n );\n }\n\n // Wire up auto-binding\n if (this.__reactAutoBindPairs.length) {\n bindAutoBindMethods(this);\n }\n\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n this.updater = updater || ReactNoopUpdateQueue;\n\n this.state = null;\n\n // ReactClasses doesn't have constructors. Instead, they use the\n // getInitialState and componentWillMount methods for initialization.\n\n var initialState = this.getInitialState ? this.getInitialState() : null;\n if (true) {\n // We allow auto-mocks to proceed as if they're returning null.\n if (\n initialState === undefined &&\n this.getInitialState._isMockFunction\n ) {\n // This is probably bad practice. Consider warning here and\n // deprecating this convenience.\n initialState = null;\n }\n }\n _invariant(\n typeof initialState === 'object' && !Array.isArray(initialState),\n '%s.getInitialState(): must return an object or null',\n Constructor.displayName || 'ReactCompositeComponent'\n );\n\n this.state = initialState;\n });\n Constructor.prototype = new ReactClassComponent();\n Constructor.prototype.constructor = Constructor;\n Constructor.prototype.__reactAutoBindPairs = [];\n\n injectedMixins.forEach(mixSpecIntoComponent.bind(null, Constructor));\n\n mixSpecIntoComponent(Constructor, IsMountedPreMixin);\n mixSpecIntoComponent(Constructor, spec);\n mixSpecIntoComponent(Constructor, IsMountedPostMixin);\n\n // Initialize the defaultProps property after all mixins have been merged.\n if (Constructor.getDefaultProps) {\n Constructor.defaultProps = Constructor.getDefaultProps();\n }\n\n if (true) {\n // This is a tag to indicate that the use of these method names is ok,\n // since it's used with createClass. If it's not, then it's likely a\n // mistake so we'll warn you to use the static property, property\n // initializer or constructor respectively.\n if (Constructor.getDefaultProps) {\n Constructor.getDefaultProps.isReactClassApproved = {};\n }\n if (Constructor.prototype.getInitialState) {\n Constructor.prototype.getInitialState.isReactClassApproved = {};\n }\n }\n\n _invariant(\n Constructor.prototype.render,\n 'createClass(...): Class specification must implement a `render` method.'\n );\n\n if (true) {\n warning(\n !Constructor.prototype.componentShouldUpdate,\n '%s has a method called ' +\n 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' +\n 'The name is phrased as a question because the function is ' +\n 'expected to return a value.',\n spec.displayName || 'A component'\n );\n warning(\n !Constructor.prototype.componentWillRecieveProps,\n '%s has a method called ' +\n 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?',\n spec.displayName || 'A component'\n );\n warning(\n !Constructor.prototype.UNSAFE_componentWillRecieveProps,\n '%s has a method called UNSAFE_componentWillRecieveProps(). ' +\n 'Did you mean UNSAFE_componentWillReceiveProps()?',\n spec.displayName || 'A component'\n );\n }\n\n // Reduce time spent doing lookups by setting these on the prototype.\n for (var methodName in ReactClassInterface) {\n if (!Constructor.prototype[methodName]) {\n Constructor.prototype[methodName] = null;\n }\n }\n\n return Constructor;\n }\n\n return createClass;\n}\n\nmodule.exports = factory;\n\n\n//# sourceURL=webpack://ReactD3/./node_modules/create-react-class/factory.js?");
/***/ }),
/***/ "./node_modules/create-react-class/index.js":
/*!**************************************************!*\
!*** ./node_modules/create-react-class/index.js ***!
\**************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n */\n\n\n\nvar React = __webpack_require__(/*! react */ \"react\");\nvar factory = __webpack_require__(/*! ./factory */ \"./node_modules/create-react-class/factory.js\");\n\nif (typeof React === 'undefined') {\n throw Error(\n 'create-react-class could not find the React object. If you are using script tags, ' +\n 'make sure that React is being loaded before create-react-class.'\n );\n}\n\n// Hack to grab NoopUpdateQueue from isomorphic React\nvar ReactNoopUpdateQueue = new React.Component().updater;\n\nmodule.exports = factory(\n React.Component,\n React.isValidElement,\n ReactNoopUpdateQueue\n);\n\n\n//# sourceURL=webpack://ReactD3/./node_modules/create-react-class/index.js?");
/***/ }),
/***/ "./node_modules/fbjs/lib/emptyFunction.js":
/*!************************************************!*\
!*** ./node_modules/fbjs/lib/emptyFunction.js ***!
\************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\n/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nfunction makeEmptyFunction(arg) {\n return function () {\n return arg;\n };\n}\n\n/**\n * This function accepts and discards inputs; it has no side effects. This is\n * primarily useful idiomatically for overridable function endpoints which\n * always need to be callable, since JS lacks a null-call idiom ala Cocoa.\n */\nvar emptyFunction = function emptyFunction() {};\n\nemptyFunction.thatReturns = makeEmptyFunction;\nemptyFunction.thatReturnsFalse = makeEmptyFunction(false);\nemptyFunction.thatReturnsTrue = makeEmptyFunction(true);\nemptyFunction.thatReturnsNull = makeEmptyFunction(null);\nemptyFunction.thatReturnsThis = function () {\n return this;\n};\nemptyFunction.thatReturnsArgument = function (arg) {\n return arg;\n};\n\nmodule.exports = emptyFunction;\n\n//# sourceURL=webpack://ReactD3/./node_modules/fbjs/lib/emptyFunction.js?");
/***/ }),
/***/ "./node_modules/fbjs/lib/emptyObject.js":
/*!**********************************************!*\
!*** ./node_modules/fbjs/lib/emptyObject.js ***!
\**********************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n */\n\n\n\nvar emptyObject = {};\n\nif (true) {\n Object.freeze(emptyObject);\n}\n\nmodule.exports = emptyObject;\n\n//# sourceURL=webpack://ReactD3/./node_modules/fbjs/lib/emptyObject.js?");
/***/ }),
/***/ "./node_modules/fbjs/lib/invariant.js":
/*!********************************************!*\
!*** ./node_modules/fbjs/lib/invariant.js ***!
\********************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n */\n\n\n\n/**\n * Use invariant() to assert state which your program assumes to be true.\n *\n * Provide sprintf-style format (only %s is supported) and arguments\n * to provide information about what broke and what you were\n * expecting.\n *\n * The invariant message will be stripped in production, but the invariant\n * will remain to ensure logic does not differ in production.\n */\n\nvar validateFormat = function validateFormat(format) {};\n\nif (true) {\n validateFormat = function validateFormat(format) {\n if (format === undefined) {\n throw new Error('invariant requires an error message argument');\n }\n };\n}\n\nfunction invariant(condition, format, a, b, c, d, e, f) {\n validateFormat(format);\n\n if (!condition) {\n var error;\n if (format === undefined) {\n error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.');\n } else {\n var args = [a, b, c, d, e, f];\n var argIndex = 0;\n error = new Error(format.replace(/%s/g, function () {\n return args[argIndex++];\n }));\n error.name = 'Invariant Violation';\n }\n\n error.framesToPop = 1; // we don't care about invariant's own frame\n throw error;\n }\n}\n\nmodule.exports = invariant;\n\n//# sourceURL=webpack://ReactD3/./node_modules/fbjs/lib/invariant.js?");
/***/ }),
/***/ "./node_modules/fbjs/lib/warning.js":
/*!******************************************!*\
!*** ./node_modules/fbjs/lib/warning.js ***!
\******************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("/**\n * Copyright (c) 2014-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n */\n\n\n\nvar emptyFunction = __webpack_require__(/*! ./emptyFunction */ \"./node_modules/fbjs/lib/emptyFunction.js\");\n\n/**\n * Similar to invariant but only logs a warning if the condition is not met.\n * This can be used to log issues in development environments in critical\n * paths. Removing the logging code for production environments will keep the\n * same logic and follow the same code paths.\n */\n\nvar warning = emptyFunction;\n\nif (true) {\n var printWarning = function printWarning(format) {\n for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n var argIndex = 0;\n var message = 'Warning: ' + format.replace(/%s/g, function () {\n return args[argIndex++];\n });\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n\n warning = function warning(condition, format) {\n if (format === undefined) {\n throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument');\n }\n\n if (format.indexOf('Failed Composite propType: ') === 0) {\n return; // Ignore CompositeComponent proptype check.\n }\n\n if (!condition) {\n for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) {\n args[_key2 - 2] = arguments[_key2];\n }\n\n printWarning.apply(undefined, [format].concat(args));\n }\n };\n}\n\nmodule.exports = warning;\n\n//# sourceURL=webpack://ReactD3/./node_modules/fbjs/lib/warning.js?");
/***/ }),
/***/ "./node_modules/object-assign/index.js":
/*!*********************************************!*\
!*** ./node_modules/object-assign/index.js ***!
\*********************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n\n\n//# sourceURL=webpack://ReactD3/./node_modules/object-assign/index.js?");
/***/ }),
/***/ "./node_modules/prop-types/checkPropTypes.js":
/*!***************************************************!*\
!*** ./node_modules/prop-types/checkPropTypes.js ***!
\***************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\n\nif (true) {\n var invariant = __webpack_require__(/*! fbjs/lib/invariant */ \"./node_modules/fbjs/lib/invariant.js\");\n var warning = __webpack_require__(/*! fbjs/lib/warning */ \"./node_modules/fbjs/lib/warning.js\");\n var ReactPropTypesSecret = __webpack_require__(/*! ./lib/ReactPropTypesSecret */ \"./node_modules/prop-types/lib/ReactPropTypesSecret.js\");\n var loggedTypeFailures = {};\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (true) {\n for (var typeSpecName in typeSpecs) {\n if (typeSpecs.hasOwnProperty(typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n invariant(typeof typeSpecs[typeSpecName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'the `prop-types` package, but received `%s`.', componentName || 'React class', location, typeSpecName, typeof typeSpecs[typeSpecName]);\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error);\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n warning(false, 'Failed %s type: %s%s', location, error.message, stack != null ? stack : '');\n }\n }\n }\n }\n}\n\nmodule.exports = checkPropTypes;\n\n\n//# sourceURL=webpack://ReactD3/./node_modules/prop-types/checkPropTypes.js?");
/***/ }),
/***/ "./node_modules/prop-types/factoryWithTypeCheckers.js":
/*!************************************************************!*\
!*** ./node_modules/prop-types/factoryWithTypeCheckers.js ***!
\************************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\n\nvar emptyFunction = __webpack_require__(/*! fbjs/lib/emptyFunction */ \"./node_modules/fbjs/lib/emptyFunction.js\");\nvar invariant = __webpack_require__(/*! fbjs/lib/invariant */ \"./node_modules/fbjs/lib/invariant.js\");\nvar warning = __webpack_require__(/*! fbjs/lib/warning */ \"./node_modules/fbjs/lib/warning.js\");\nvar assign = __webpack_require__(/*! object-assign */ \"./node_modules/object-assign/index.js\");\n\nvar ReactPropTypesSecret = __webpack_require__(/*! ./lib/ReactPropTypesSecret */ \"./node_modules/prop-types/lib/ReactPropTypesSecret.js\");\nvar checkPropTypes = __webpack_require__(/*! ./checkPropTypes */ \"./node_modules/prop-types/checkPropTypes.js\");\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<<anonymous>>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message) {\n this.message = message;\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (true) {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n invariant(\n false,\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n } else if (\"development\" !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n warning(\n false,\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `%s` prop on `%s`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.',\n propFullName,\n componentName\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunction.thatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n true ? warning(false, 'Invalid argument supplied to oneOf, expected an instance of array.') : undefined;\n return emptyFunction.thatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + propValue + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (propValue.hasOwnProperty(key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n true ? warning(false, 'Invalid argument supplied to oneOfType, expected an instance of array.') : undefined;\n return emptyFunction.thatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n warning(\n false,\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received %s at index %s.',\n getPostfixForTypeWarning(checker),\n i\n );\n return emptyFunction.thatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret) == null) {\n return null;\n }\n }\n\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (!checker) {\n continue;\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from\n // props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n\n\n//# sourceURL=webpack://ReactD3/./node_modules/prop-types/factoryWithTypeCheckers.js?");
/***/ }),
/***/ "./node_modules/prop-types/index.js":
/*!******************************************!*\
!*** ./node_modules/prop-types/index.js ***!
\******************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
eval("/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (true) {\n var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' &&\n Symbol.for &&\n Symbol.for('react.element')) ||\n 0xeac7;\n\n var isValidElement = function(object) {\n return typeof object === 'object' &&\n object !== null &&\n object.$$typeof === REACT_ELEMENT_TYPE;\n };\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = __webpack_require__(/*! ./factoryWithTypeCheckers */ \"./node_modules/prop-types/factoryWithTypeCheckers.js\")(isValidElement, throwOnDirectAccess);\n} else {}\n\n\n//# sourceURL=webpack://ReactD3/./node_modules/prop-types/index.js?");
/***/ }),
/***/ "./node_modules/prop-types/lib/ReactPropTypesSecret.js":
/*!*************************************************************!*\
!*** ./node_modules/prop-types/lib/ReactPropTypesSecret.js ***!
\*************************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n\n\n//# sourceURL=webpack://ReactD3/./node_modules/prop-types/lib/ReactPropTypesSecret.js?");
/***/ }),
/***/ "./src/AccessorMixin.jsx":
/*!*******************************!*\
!*** ./src/AccessorMixin.jsx ***!
\*******************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar func = _propTypes.default.func;\nvar AccessorMixin = {\n propTypes: {\n label: func,\n values: func,\n x: func,\n y: func,\n y0: func\n },\n getDefaultProps: function getDefaultProps() {\n return {\n label: function label(stack) {\n return stack.label;\n },\n values: function values(stack) {\n return stack.values;\n },\n x: function x(e) {\n return e.x;\n },\n y: function y(e) {\n return e.y;\n },\n y0: function y0() {\n return 0;\n }\n };\n }\n};\nvar _default = AccessorMixin;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/AccessorMixin.jsx?");
/***/ }),
/***/ "./src/AreaChart.jsx":
/*!***************************!*\
!*** ./src/AreaChart.jsx ***!
\***************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nvar _d = _interopRequireDefault(__webpack_require__(/*! d3 */ \"d3\"));\n\nvar _Chart = _interopRequireDefault(__webpack_require__(/*! ./Chart */ \"./src/Chart.jsx\"));\n\nvar _Axis = _interopRequireDefault(__webpack_require__(/*! ./Axis */ \"./src/Axis.jsx\"));\n\nvar _Path = _interopRequireDefault(__webpack_require__(/*! ./Path */ \"./src/Path.jsx\"));\n\nvar _Tooltip = _interopRequireDefault(__webpack_require__(/*! ./Tooltip */ \"./src/Tooltip.jsx\"));\n\nvar _DefaultPropsMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultPropsMixin */ \"./src/DefaultPropsMixin.jsx\"));\n\nvar _HeightWidthMixin = _interopRequireDefault(__webpack_require__(/*! ./HeightWidthMixin */ \"./src/HeightWidthMixin.jsx\"));\n\nvar _ArrayifyMixin = _interopRequireDefault(__webpack_require__(/*! ./ArrayifyMixin */ \"./src/ArrayifyMixin.jsx\"));\n\nvar _StackAccessorMixin = _interopRequireDefault(__webpack_require__(/*! ./StackAccessorMixin */ \"./src/StackAccessorMixin.jsx\"));\n\nvar _StackDataMixin = _interopRequireDefault(__webpack_require__(/*! ./StackDataMixin */ \"./src/StackDataMixin.jsx\"));\n\nvar _DefaultScalesMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultScalesMixin */ \"./src/DefaultScalesMixin.jsx\"));\n\nvar _TooltipMixin = _interopRequireDefault(__webpack_require__(/*! ./TooltipMixin */ \"./src/TooltipMixin.jsx\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _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; }; return _extends.apply(this, arguments); }\n\nvar array = _propTypes.default.array,\n func = _propTypes.default.func,\n string = _propTypes.default.string;\nvar DataSet = (0, _createReactClass.default)({\n displayName: \"DataSet\",\n propTypes: {\n data: array.isRequired,\n area: func.isRequired,\n line: func.isRequired,\n colorScale: func.isRequired,\n stroke: func.isRequired\n },\n render: function render() {\n var _this$props = this.props,\n data = _this$props.data,\n area = _this$props.area,\n colorScale = _this$props.colorScale,\n values = _this$props.values,\n label = _this$props.label,\n onMouseEnter = _this$props.onMouseEnter,\n onMouseLeave = _this$props.onMouseLeave;\n var areas = data.map(function (stack, index) {\n return _react.default.createElement(_Path.default, {\n key: \"\".concat(label(stack), \".\").concat(index),\n className: \"area\",\n stroke: \"none\",\n fill: colorScale(label(stack)),\n d: area(values(stack)),\n onMouseEnter: onMouseEnter,\n onMouseLeave: onMouseLeave,\n data: data\n });\n });\n return _react.default.createElement(\"g\", null, areas);\n }\n});\nvar AreaChart = (0, _createReactClass.default)({\n displayName: \"AreaChart\",\n mixins: [_DefaultPropsMixin.default, _HeightWidthMixin.default, _ArrayifyMixin.default, _StackAccessorMixin.default, _StackDataMixin.default, _DefaultScalesMixin.default, _TooltipMixin.default],\n propTypes: {\n interpolate: string,\n stroke: func\n },\n getDefaultProps: function getDefaultProps() {\n return {\n interpolate: 'linear',\n stroke: _d.default.scale.category20()\n };\n },\n _tooltipHtml: function _tooltipHtml(d, position) {\n var _this$props2 = this.props,\n x = _this$props2.x,\n y0 = _this$props2.y0,\n y = _this$props2.y,\n values = _this$props2.values,\n label = _this$props2.label;\n var xScale = this._xScale;\n var yScale = this._yScale;\n var xValueCursor = xScale.invert(position[0]);\n\n var xBisector = _d.default.bisector(function (e) {\n return x(e);\n }).right;\n\n var xIndex = xBisector(values(d[0]), xScale.invert(position[0]));\n xIndex = xIndex == values(d[0]).length ? xIndex - 1 : xIndex;\n var xIndexRight = xIndex == values(d[0]).length ? xIndex - 1 : xIndex;\n var xValueRight = x(values(d[0])[xIndexRight]);\n var xIndexLeft = xIndex == 0 ? xIndex : xIndex - 1;\n var xValueLeft = x(values(d[0])[xIndexLeft]);\n\n if (Math.abs(xValueCursor - xValueRight) < Math.abs(xValueCursor - xValueLeft)) {\n xIndex = xIndexRight;\n } else {\n xIndex = xIndexLeft;\n }\n\n var yValueCursor = yScale.invert(position[1]);\n\n var yBisector = _d.default.bisector(function (e) {\n return y0(values(e)[xIndex]) + y(values(e)[xIndex]);\n }).left;\n\n var yIndex = yBisector(d, yValueCursor);\n yIndex = yIndex == d.length ? yIndex - 1 : yIndex;\n var yValue = y(values(d[yIndex])[xIndex]);\n var yValueCumulative = y0(values(d[d.length - 1])[xIndex]) + y(values(d[d.length - 1])[xIndex]);\n var xValue = x(values(d[yIndex])[xIndex]);\n var xPos = xScale(xValue);\n var yPos = yScale(y0(values(d[yIndex])[xIndex]) + yValue);\n return [this.props.tooltipHtml(yValue, yValueCumulative, xValue, label(d[yIndex])), xPos, yPos];\n },\n render: function render() {\n var _this$props3 = this.props,\n height = _this$props3.height,\n width = _this$props3.width,\n margin = _this$props3.margin,\n viewBox = _this$props3.viewBox,\n preserveAspectRatio = _this$props3.preserveAspectRatio,\n colorScale = _this$props3.colorScale,\n interpolate = _this$props3.interpolate,\n stroke = _this$props3.stroke,\n values = _this$props3.values,\n label = _this$props3.label,\n x = _this$props3.x,\n y = _this$props3.y,\n y0 = _this$props3.y0,\n xAxis = _this$props3.xAxis,\n yAxis = _this$props3.yAxis,\n yOrientation = _this$props3.yOrientation;\n var data = this._data;\n var innerWidth = this._innerWidth;\n var innerHeight = this._innerHeight;\n var xScale = this._xScale;\n var yScale = this._yScale;\n\n var line = _d.default.svg.line().x(function (e) {\n return xScale(x(e));\n }).y(function (e) {\n return yScale(y0(e) + y(e));\n }).interpolate(interpolate);\n\n var area = _d.default.svg.area().x(function (e) {\n return xScale(x(e));\n }).y0(function (e) {\n return yScale(yScale.domain()[0] + y0(e));\n }).y1(function (e) {\n return yScale(y0(e) + y(e));\n }).interpolate(interpolate);\n\n return _react.default.createElement(\"div\", null, _react.default.createElement(_Chart.default, {\n height: height,\n width: width,\n margin: margin,\n viewBox: viewBox,\n preserveAspectRatio: preserveAspectRatio\n }, _react.default.createElement(DataSet, {\n data: data,\n line: line,\n area: area,\n colorScale: colorScale,\n stroke: stroke,\n label: label,\n values: values,\n onMouseEnter: this.onMouseEnter,\n onMouseLeave: this.onMouseLeave\n }), _react.default.createElement(_Axis.default, _extends({\n className: \"x axis\",\n orientation: \"bottom\",\n scale: xScale,\n height: innerHeight,\n width: innerWidth\n }, xAxis)), _react.default.createElement(_Axis.default, _extends({\n className: \"y axis\",\n orientation: yOrientation ? yOrientation : 'left',\n scale: yScale,\n height: innerHeight,\n width: innerWidth\n }, yAxis)), this.props.children), _react.default.createElement(_Tooltip.default, this.state.tooltip));\n }\n});\nvar _default = AreaChart;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/AreaChart.jsx?");
/***/ }),
/***/ "./src/ArrayifyMixin.jsx":
/*!*******************************!*\
!*** ./src/ArrayifyMixin.jsx ***!
\*******************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar ArrayifyMixin = {\n componentWillMount: function componentWillMount() {\n this._arrayify(this.props);\n },\n componentWillReceiveProps: function componentWillReceiveProps(nextProps) {\n this._arrayify(nextProps);\n },\n _arrayify: function _arrayify(props) {\n if (props.data === null) {\n this._data = [{\n label: 'No data available',\n values: [{\n x: 'No data available',\n y: 1\n }]\n }];\n } else if (!Array.isArray(props.data)) {\n this._data = [props.data];\n } else {\n this._data = props.data;\n }\n }\n};\nvar _default = ArrayifyMixin;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/ArrayifyMixin.jsx?");
/***/ }),
/***/ "./src/Axis.jsx":
/*!**********************!*\
!*** ./src/Axis.jsx ***!
\**********************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar array = _propTypes.default.array,\n func = _propTypes.default.func,\n oneOf = _propTypes.default.oneOf,\n number = _propTypes.default.number,\n string = _propTypes.default.string;\nvar Axis = (0, _createReactClass.default)({\n displayName: \"Axis\",\n propTypes: {\n tickArguments: array,\n tickValues: array,\n tickFormat: func,\n tickDirection: oneOf(['horizontal', 'vertical', 'diagonal']),\n innerTickSize: number,\n tickPadding: number,\n outerTickSize: number,\n scale: func.isRequired,\n className: string,\n zero: number,\n orientation: oneOf(['top', 'bottom', 'left', 'right']).isRequired,\n label: string\n },\n getDefaultProps: function getDefaultProps() {\n return {\n tickArguments: [10],\n tickValues: null,\n tickFormat: null,\n tickDirection: 'horizontal',\n innerTickSize: 6,\n tickPadding: 3,\n outerTickSize: 6,\n className: 'axis',\n zero: 0,\n label: ''\n };\n },\n _getTranslateString: function _getTranslateString() {\n var _this$props = this.props,\n orientation = _this$props.orientation,\n height = _this$props.height,\n width = _this$props.width,\n zero = _this$props.zero;\n\n if (orientation === 'top') {\n return \"translate(0, \".concat(zero, \")\");\n } else if (orientation === 'bottom') {\n return \"translate(0, \".concat(zero == 0 ? height : zero, \")\");\n } else if (orientation === 'left') {\n return \"translate(\".concat(zero, \", 0)\");\n } else if (orientation === 'right') {\n return \"translate(\".concat(zero == 0 ? width : zero, \", 0)\");\n } else {\n return '';\n }\n },\n render: function render() {\n var _this$props2 = this.props,\n height = _this$props2.height,\n tickArguments = _this$props2.tickArguments,\n tickValues = _this$props2.tickValues,\n tickDirection = _this$props2.tickDirection,\n innerTickSize = _this$props2.innerTickSize,\n tickPadding = _this$props2.tickPadding,\n outerTickSize = _this$props2.outerTickSize,\n scale = _this$props2.scale,\n orientation = _this$props2.orientation,\n zero = _this$props2.zero;\n var _this$props3 = this.props,\n width = _this$props3.width,\n className = _this$props3.className,\n label = _this$props3.label;\n var tickFormat = this.props.tickFormat;\n var ticks = tickValues == null ? scale.ticks ? scale.ticks.apply(scale, tickArguments) : scale.domain() : tickValues;\n\n if (!tickFormat) {\n if (scale.tickFormat) {\n tickFormat = scale.tickFormat.apply(scale, tickArguments);\n } else {\n tickFormat = function tickFormat(x) {\n return x;\n };\n }\n } // TODO: is there a cleaner way? removes the 0 tick if axes are crossing\n\n\n if (zero != height && zero != width && zero != 0) {\n ticks = ticks.filter(function (element) {\n return element != 0;\n });\n }\n\n var tickSpacing = Math.max(innerTickSize, 0) + tickPadding;\n var sign = orientation === 'top' || orientation === 'left' ? -1 : 1;\n\n var range = this._d3ScaleRange(scale);\n\n var activeScale = scale.rangeBand ? function (e) {\n return scale(e) + scale.rangeBand() / 2;\n } : scale;\n var transform,\n x,\n y,\n x2,\n y2,\n dy,\n textAnchor,\n d,\n labelElement,\n tickRotation = 0;\n\n if (orientation === 'bottom' || orientation === 'top') {\n transform = 'translate({}, 0)';\n x = 0;\n y = sign * tickSpacing;\n x2 = 0;\n y2 = sign * innerTickSize;\n dy = sign < 0 ? '0em' : '.71em';\n textAnchor = 'middle';\n d = \"M\".concat(range[0], \", \").concat(sign * outerTickSize, \"V0H\").concat(range[1], \"V\").concat(sign * outerTickSize);\n\n if (tickDirection === 'vertical') {\n tickRotation = -90;\n x = -tickSpacing;\n y = -innerTickSize;\n textAnchor = 'end';\n } else if (tickDirection === 'diagonal') {\n tickRotation = -60;\n x = -tickSpacing;\n y = 0;\n textAnchor = 'end';\n }\n\n labelElement = _react.default.createElement(\"text\", {\n className: \"\".concat(className, \" label\"),\n textAnchor: 'end',\n x: width,\n y: -6\n }, label);\n } else {\n transform = 'translate(0, {})';\n x = sign * tickSpacing;\n y = 0;\n x2 = sign * innerTickSize;\n y2 = 0;\n dy = '.32em';\n textAnchor = sign < 0 ? 'end' : 'start';\n d = \"M\".concat(sign * outerTickSize, \", \").concat(range[0], \"H0V\").concat(range[1], \"H\").concat(sign * outerTickSize);\n\n if (tickDirection === 'vertical') {\n tickRotation = -90;\n x -= sign * tickSpacing;\n y = -(tickSpacing + innerTickSize);\n textAnchor = 'middle';\n } else if (tickDirection === 'diagonal') {\n tickRotation = -60;\n x -= sign * tickSpacing;\n y = -(tickSpacing + innerTickSize);\n textAnchor = 'middle';\n }\n\n labelElement = _react.default.createElement(\"text\", {\n className: \"\".concat(className, \" label\"),\n textAnchor: \"end\",\n y: 6,\n dy: orientation === 'left' ? '.75em' : '-1.25em',\n transform: \"rotate(-90)\"\n }, label);\n }\n\n var tickElements = ticks.map(function (tick, index) {\n var position = activeScale(tick);\n var translate = transform.replace('{}', position);\n return _react.default.createElement(\"g\", {\n key: \"\".concat(tick, \".\").concat(index),\n className: \"tick\",\n transform: translate\n }, _react.default.createElement(\"line\", {\n x2: x2,\n y2: y2,\n stroke: \"#aaa\"\n }), _react.default.createElement(\"text\", {\n x: x,\n y: y,\n dy: dy,\n textAnchor: textAnchor,\n transform: \"rotate(\".concat(tickRotation, \")\")\n }, tickFormat(tick)));\n });\n\n var pathElement = _react.default.createElement(\"path\", {\n className: \"domain\",\n d: d,\n fill: \"none\",\n stroke: \"#aaa\"\n });\n\n var axisBackground = _react.default.createElement(\"rect\", {\n className: \"axis-background\",\n fill: \"none\"\n });\n\n return _react.default.createElement(\"g\", {\n ref: \"axis\",\n className: className,\n transform: this._getTranslateString(),\n style: {\n shapeRendering: 'crispEdges'\n }\n }, axisBackground, tickElements, pathElement, labelElement);\n },\n _d3ScaleExtent: function _d3ScaleExtent(domain) {\n var start = domain[0];\n var stop = domain[domain.length - 1];\n return start < stop ? [start, stop] : [stop, start];\n },\n _d3ScaleRange: function _d3ScaleRange(scale) {\n return scale.rangeExtent ? scale.rangeExtent() : this._d3ScaleExtent(scale.range());\n }\n});\nvar _default = Axis;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/Axis.jsx?");
/***/ }),
/***/ "./src/Bar.jsx":
/*!*********************!*\
!*** ./src/Bar.jsx ***!
\*********************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar number = _propTypes.default.number,\n string = _propTypes.default.string,\n array = _propTypes.default.array,\n object = _propTypes.default.object,\n func = _propTypes.default.func,\n oneOfType = _propTypes.default.oneOfType;\nvar Bar = (0, _createReactClass.default)({\n displayName: \"Bar\",\n propTypes: {\n width: number.isRequired,\n height: number.isRequired,\n x: number.isRequired,\n y: number.isRequired,\n fill: string.isRequired,\n data: oneOfType([array, object]).isRequired,\n onMouseEnter: func,\n onMouseLeave: func\n },\n render: function render() {\n var _this$props = this.props,\n x = _this$props.x,\n y = _this$props.y,\n width = _this$props.width,\n height = _this$props.height,\n fill = _this$props.fill,\n data = _this$props.data,\n onMouseEnter = _this$props.onMouseEnter,\n _onMouseLeave = _this$props.onMouseLeave;\n return _react.default.createElement(\"rect\", {\n className: \"bar\",\n x: x,\n y: y,\n width: width,\n height: height,\n fill: fill,\n onMouseMove: function onMouseMove(e) {\n return onMouseEnter(e, data);\n },\n onMouseLeave: function onMouseLeave(e) {\n return _onMouseLeave(e);\n }\n });\n }\n});\nvar _default = Bar;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/Bar.jsx?");
/***/ }),
/***/ "./src/BarChart.jsx":
/*!**************************!*\
!*** ./src/BarChart.jsx ***!
\**************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nvar _Chart = _interopRequireDefault(__webpack_require__(/*! ./Chart */ \"./src/Chart.jsx\"));\n\nvar _Axis = _interopRequireDefault(__webpack_require__(/*! ./Axis */ \"./src/Axis.jsx\"));\n\nvar _Bar = _interopRequireDefault(__webpack_require__(/*! ./Bar */ \"./src/Bar.jsx\"));\n\nvar _Tooltip = _interopRequireDefault(__webpack_require__(/*! ./Tooltip */ \"./src/Tooltip.jsx\"));\n\nvar _DefaultPropsMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultPropsMixin */ \"./src/DefaultPropsMixin.jsx\"));\n\nvar _HeightWidthMixin = _interopRequireDefault(__webpack_require__(/*! ./HeightWidthMixin */ \"./src/HeightWidthMixin.jsx\"));\n\nvar _ArrayifyMixin = _interopRequireDefault(__webpack_require__(/*! ./ArrayifyMixin */ \"./src/ArrayifyMixin.jsx\"));\n\nvar _StackAccessorMixin = _interopRequireDefault(__webpack_require__(/*! ./StackAccessorMixin */ \"./src/StackAccessorMixin.jsx\"));\n\nvar _StackDataMixin = _interopRequireDefault(__webpack_require__(/*! ./StackDataMixin */ \"./src/StackDataMixin.jsx\"));\n\nvar _DefaultScalesMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultScalesMixin */ \"./src/DefaultScalesMixin.jsx\"));\n\nvar _TooltipMixin = _interopRequireDefault(__webpack_require__(/*! ./TooltipMixin */ \"./src/TooltipMixin.jsx\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _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; }; return _extends.apply(this, arguments); }\n\nvar array = _propTypes.default.array,\n func = _propTypes.default.func;\nvar DataSet = (0, _createReactClass.default)({\n displayName: \"DataSet\",\n propTypes: {\n data: array.isRequired,\n xScale: func.isRequired,\n yScale: func.isRequired,\n colorScale: func.isRequired,\n values: func.isRequired,\n label: func.isRequired,\n x: func.isRequired,\n y: func.isRequired,\n y0: func.isRequired\n },\n render: function render() {\n var _this$props = this.props,\n data = _this$props.data,\n xScale = _this$props.xScale,\n yScale = _this$props.yScale,\n colorScale = _this$props.colorScale,\n values = _this$props.values,\n label = _this$props.label,\n x = _this$props.x,\n y = _this$props.y,\n y0 = _this$props.y0,\n onMouseEnter = _this$props.onMouseEnter,\n onMouseLeave = _this$props.onMouseLeave,\n groupedBars = _this$props.groupedBars,\n colorByLabel = _this$props.colorByLabel;\n var bars;\n\n if (groupedBars) {\n bars = data.map(function (stack, serieIndex) {\n return values(stack).map(function (e, index) {\n var yVal = y(e) < 0 ? yScale(0) : yScale(y(e));\n return _react.default.createElement(_Bar.default, {\n key: \"\".concat(label(stack), \".\").concat(index),\n width: xScale.rangeBand() / data.length,\n height: Math.abs(yScale(0) - yScale(y(e))),\n x: xScale(x(e)) + xScale.rangeBand() * serieIndex / data.length,\n y: yVal,\n fill: colorScale(label(stack)),\n data: e,\n onMouseEnter: onMouseEnter,\n onMouseLeave: onMouseLeave\n });\n });\n });\n } else {\n bars = data.map(function (stack) {\n return values(stack).map(function (e, index) {\n var color = colorByLabel ? colorScale(label(stack)) : colorScale(x(e));\n var yVal = y(e) < 0 ? yScale(y0(e)) : yScale(y0(e) + y(e));\n return _react.default.createElement(_Bar.default, {\n key: \"\".concat(label(stack), \".\").concat(index),\n width: xScale.rangeBand(),\n height: Math.abs(yScale(y0(e) + y(e)) - yScale(y0(e))),\n x: xScale(x(e)),\n y: yVal,\n fill: color,\n data: e,\n onMouseEnter: onMouseEnter,\n onMouseLeave: onMouseLeave\n });\n });\n });\n }\n\n return _react.default.createElement(\"g\", null, bars);\n }\n});\nvar BarChart = (0, _createReactClass.default)({\n displayName: \"BarChart\",\n mixins: [_DefaultPropsMixin.default, _HeightWidthMixin.default, _ArrayifyMixin.default, _StackAccessorMixin.default, _StackDataMixin.default, _DefaultScalesMixin.default, _TooltipMixin.default],\n getDefaultProps: function getDefaultProps() {\n return {\n colorByLabel: true\n };\n },\n _tooltipHtml: function _tooltipHtml(d) {\n var xScale = this._xScale;\n var yScale = this._yScale;\n var html = this.props.tooltipHtml(this.props.x(d), this.props.y0(d), this.props.y(d));\n var midPoint = xScale.rangeBand() / 2;\n var xPos = midPoint + xScale(this.props.x(d));\n var topStack = this._data[this._data.length - 1].values;\n var topElement = null; // TODO: this might not scale if dataset is huge.\n // consider pre-computing yPos for each X\n\n for (var i = 0; i < topStack.length; i++) {\n if (this.props.x(topStack[i]) === this.props.x(d)) {\n topElement = topStack[i];\n break;\n }\n }\n\n var yPos = yScale(this.props.y0(topElement) + this.props.y(topElement));\n return [html, xPos, yPos];\n },\n render: function render() {\n var _this$props2 = this.props,\n xAxis = _this$props2.xAxis,\n yAxis = _this$props2.yAxis,\n height = _this$props2.height,\n width = _this$props2.width,\n margin = _this$props2.margin,\n viewBox = _this$props2.viewBox,\n preserveAspectRatio = _this$props2.preserveAspectRatio,\n colorScale = _this$props2.colorScale,\n values = _this$props2.values,\n label = _this$props2.label,\n y = _this$props2.y,\n y0 = _this$props2.y0,\n x = _this$props2.x,\n groupedBars = _this$props2.groupedBars,\n colorByLabel = _this$props2.colorByLabel,\n tickFormat = _this$props2.tickFormat;\n var data = this._data;\n var innerWidth = this._innerWidth;\n var innerHeight = this._innerHeight;\n var xScale = this._xScale;\n var yScale = this._yScale;\n var yIntercept = this._yIntercept;\n return _react.default.createElement(\"div\", null, _react.default.createElement(_Chart.default, {\n height: height,\n width: width,\n margin: margin,\n viewBox: viewBox,\n preserveAspectRatio: preserveAspectRatio\n }, _react.default.createElement(DataSet, {\n data: data,\n xScale: xScale,\n yScale: yScale,\n colorScale: colorScale,\n values: values,\n label: label,\n y: y,\n y0: y0,\n x: x,\n onMouseEnter: this.onMouseEnter,\n onMouseLeave: this.onMouseLeave,\n groupedBars: groupedBars,\n colorByLabel: colorByLabel\n }), _react.default.createElement(_Axis.default, _extends({\n className: \"x axis\",\n orientation: \"bottom\",\n scale: xScale,\n height: innerHeight,\n width: innerWidth,\n zero: yIntercept,\n tickFormat: tickFormat\n }, xAxis)), _react.default.createElement(_Axis.default, _extends({\n className: \"y axis\",\n orientation: \"left\",\n scale: yScale,\n height: innerHeight,\n width: innerWidth,\n tickFormat: tickFormat\n }, yAxis)), this.props.children), _react.default.createElement(_Tooltip.default, this.state.tooltip));\n }\n});\nvar _default = BarChart;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/BarChart.jsx?");
/***/ }),
/***/ "./src/Brush.jsx":
/*!***********************!*\
!*** ./src/Brush.jsx ***!
\***********************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _reactDom = _interopRequireDefault(__webpack_require__(/*! react-dom */ \"react-dom\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nvar _Chart = _interopRequireDefault(__webpack_require__(/*! ./Chart */ \"./src/Chart.jsx\"));\n\nvar _Axis = _interopRequireDefault(__webpack_require__(/*! ./Axis */ \"./src/Axis.jsx\"));\n\nvar _HeightWidthMixin = _interopRequireDefault(__webpack_require__(/*! ./HeightWidthMixin */ \"./src/HeightWidthMixin.jsx\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _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; }; return _extends.apply(this, arguments); }\n\n// Adapted for React from https://github.com/mbostock/d3/blob/master/src/svg/brush.js\n// TODO: Add D3 License\nvar _d3SvgBrushCursor = {\n n: 'ns-resize',\n e: 'ew-resize',\n s: 'ns-resize',\n w: 'ew-resize',\n nw: 'nwse-resize',\n ne: 'nesw-resize',\n se: 'nwse-resize',\n sw: 'nesw-resize'\n};\nvar _d3SvgBrushResizes = [['n', 'e', 's', 'w', 'nw', 'ne', 'se', 'sw'], ['e', 'w'], ['n', 's'], []]; // TODO: add y axis support\n\nvar Brush = (0, _createReactClass.default)({\n displayName: \"Brush\",\n mixins: [_HeightWidthMixin.default],\n getInitialState: function getInitialState() {\n return {\n resizers: _d3SvgBrushResizes[0],\n xExtent: [0, 0],\n yExtent: [0, 0],\n xExtentDomain: undefined,\n yExtentDomain: undefined\n };\n },\n getDefaultProps: function getDefaultProps() {\n return {\n xScale: null,\n yScale: null\n };\n },\n componentWillMount: function componentWillMount() {\n this._extent(this.props.extent);\n\n this.setState({\n resizers: _d3SvgBrushResizes[!this.props.xScale << 1 | !this.props.yScale]\n });\n },\n componentWillReceiveProps: function componentWillReceiveProps(nextProps) {\n // when <Brush/> is used inside a component\n // we should not set the extent prop on every redraw of the parent, because it will\n // stop us from actually setting the extent with the brush.\n if (nextProps.xScale !== this.props.xScale) {\n this._extent(nextProps.extent, nextProps.xScale);\n\n this.setState({\n resizers: _d3SvgBrushResizes[!this.props.xScale << 1 | !this.props.yScale]\n });\n }\n },\n render: function render() {\n var _this = this;\n\n // TODO: remove this.state this.props\n var xRange = this.props.xScale ? this._d3ScaleRange(this.props.xScale) : null;\n var yRange = this.props.yScale ? this._d3ScaleRange(this.props.yScale) : null;\n\n var background = _react.default.createElement(\"rect\", {\n className: \"background\",\n style: {\n visibility: 'visible',\n cursor: 'crosshair'\n },\n x: xRange ? xRange[0] : '',\n width: xRange ? xRange[1] - xRange[0] : '',\n y: yRange ? yRange[0] : '',\n height: yRange ? yRange[1] - yRange[0] : this._innerHeight,\n onMouseDown: this._onMouseDownBackground\n }); // TODO: it seems like actually we can have both x and y scales at the same time. need to find example.\n\n\n var extent;\n\n if (this.props.xScale) {\n extent = _react.default.createElement(\"rect\", {\n className: \"extent\",\n style: {\n cursor: 'move'\n },\n x: this.state.xExtent[0],\n width: this.state.xExtent[1] - this.state.xExtent[0],\n height: this._innerHeight,\n onMouseDown: this._onMouseDownExtent\n });\n }\n\n var resizers = this.state.resizers.map(function (e) {\n return _react.default.createElement(\"g\", {\n key: e,\n className: \"resize \".concat(e),\n style: {\n cursor: _d3SvgBrushCursor[e]\n },\n transform: \"translate(\".concat(_this.state.xExtent[+/e$/.test(e)], \", \").concat(_this.state.yExtent[+/^s/.test(e)], \")\"),\n onMouseDown: function onMouseDown(event) {\n _this._onMouseDownResizer(event, e);\n }\n }, _react.default.createElement(\"rect\", {\n x: /[ew]$/.test(e) ? -3 : null,\n y: /^[ns]/.test(e) ? -3 : null,\n width: \"6\",\n height: _this._innerHeight,\n style: {\n visibility: 'hidden',\n display: _this._empty() ? 'none' : null\n }\n }));\n });\n var _this$props = this.props,\n height = _this$props.height,\n width = _this$props.width,\n margin = _this$props.margin,\n viewBox = _this$props.viewBox,\n preserveAspectRatio = _this$props.preserveAspectRatio;\n return _react.default.createElement(\"div\", null, _react.default.createElement(_Chart.default, {\n height: height,\n width: width,\n margin: margin,\n viewBox: viewBox,\n preserveAspectRatio: preserveAspectRatio\n }, _react.default.createElement(\"g\", {\n style: {\n pointerEvents: 'all'\n },\n onMouseUp: this._onMouseUp,\n onMouseMove: this._onMouseMove\n }, background, extent, resizers), _react.default.createElement(_Axis.default, _extends({\n className: \"x axis\",\n orientation: \"bottom\",\n scale: this.props.xScale,\n height: this._innerHeight,\n width: this._innerWidth\n }, this.props.xAxis)), this.props.children));\n },\n // TODO: Code duplicated in TooltipMixin.jsx, move outside.\n _getMousePosition: function _getMousePosition(e) {\n var svg = _reactDom.default.findDOMNode(this).getElementsByTagName('svg')[0];\n\n var position;\n\n if (svg.createSVGPoint) {\n var point = svg.createSVGPoint();\n point.x = e.clientX;\n point.y = e.clientY;\n point = point.matrixTransform(svg.getScreenCTM().inverse());\n position = [point.x - this.props.margin.left, point.y - this.props.margin.top];\n } else {\n var rect = svg.getBoundingClientRect();\n position = [e.clientX - rect.left - svg.clientLeft - this.props.margin.left, e.clientY - rect.top - svg.clientTop - this.props.margin.left];\n }\n\n return position;\n },\n _onMouseDownBackground: function _onMouseDownBackground(e) {\n e.preventDefault();\n\n var range = this._d3ScaleRange(this.props.xScale);\n\n var point = this._getMousePosition(e);\n\n var size = this.state.xExtent[1] - this.state.xExtent[0];\n range[1] -= size;\n var min = Math.max(range[0], Math.min(range[1], point[0]));\n this.setState({\n xExtent: [min, min + size]\n });\n },\n // TODO: use constants instead of strings\n _onMouseDownExtent: function _onMouseDownExtent(e) {\n e.preventDefault();\n this._mouseMode = 'drag';\n\n var point = this._getMousePosition(e);\n\n var distanceFromBorder = point[0] - this.state.xExtent[0];\n this._startPosition = distanceFromBorder;\n },\n _onMouseDownResizer: function _onMouseDownResizer(e, dir) {\n e.preventDefault();\n this._mouseMode = 'resize';\n this._resizeDir = dir;\n },\n _onDrag: function _onDrag(e) {\n var range = this._d3ScaleRange(this.props.xScale);\n\n var point = this._getMousePosition(e);\n\n var size = this.state.xExtent[1] - this.state.xExtent[0];\n range[1] -= size;\n var min = Math.max(range[0], Math.min(range[1], point[0] - this._startPosition));\n this.setState({\n xExtent: [min, min + size],\n xExtentDomain: null\n });\n },\n _onResize: function _onResize(e) {\n var range = this._d3ScaleRange(this.props.xScale);\n\n var point = this._getMousePosition(e); // Don't let the extent go outside of its limits\n // TODO: support clamp argument of D3\n\n\n var min = Math.max(range[0], Math.min(range[1], point[0]));\n\n if (this._resizeDir == 'w') {\n if (min > this.state.xExtent[1]) {\n this.setState({\n xExtent: [this.state.xExtent[1], min],\n xExtentDomain: null\n });\n this._resizeDir = 'e';\n } else {\n this.setState({\n xExtent: [min, this.state.xExtent[1]],\n xExtentDomain: null\n });\n }\n } else if (this._resizeDir == 'e') {\n if (min < this.state.xExtent[0]) {\n this.setState({\n xExtent: [min, this.state.xExtent[0]],\n xExtentDomain: null\n });\n this._resizeDir = 'w';\n } else {\n this.setState({\n xExtent: [this.state.xExtent[0], min],\n xExtentDomain: null\n });\n }\n }\n },\n _onMouseMove: function _onMouseMove(e) {\n e.preventDefault();\n\n if (this._mouseMode == 'resize') {\n this._onResize(e);\n } else if (this._mouseMode == 'drag') {\n this._onDrag(e);\n }\n },\n _onMouseUp: function _onMouseUp(e) {\n e.preventDefault();\n this._mouseMode = null;\n this.props.onChange(this._extent());\n },\n _extent: function _extent(z, xScale) {\n var x = xScale || this.props.xScale;\n var y = this.props.yScale;\n var _this$state = this.state,\n xExtent = _this$state.xExtent,\n yExtent = _this$state.yExtent,\n xExtentDomain = _this$state.xExtentDomain,\n yExtentDomain = _this$state.yExtentDomain;\n var x0, x1, y0, y1, t; // Invert the pixel extent to data-space.\n\n if (!arguments.length) {\n if (x) {\n if (xExtentDomain) {\n x0 = xExtentDomain[0], x1 = xExtentDomain[1];\n } else {\n x0 = xExtent[0], x1 = xExtent[1];\n if (x.invert) x0 = x.invert(x0), x1 = x.invert(x1);\n if (x1 < x0) t = x0, x0 = x1, x1 = t;\n }\n }\n\n if (y) {\n if (yExtentDomain) {\n y0 = yExtentDomain[0], y1 = yExtentDomain[1];\n } else {\n y0 = yExtent[0], y1 = yExtent[1];\n if (y.invert) y0 = y.invert(y0), y1 = y.invert(y1);\n if (y1 < y0) t = y0, y0 = y1, y1 = t;\n }\n }\n\n return x && y ? [[x0, y0], [x1, y1]] : x ? [x0, x1] : y && [y0, y1];\n } // Scale the data-space extent to pixels.\n\n\n if (x) {\n x0 = z[0], x1 = z[1];\n if (y) x0 = x0[0], x1 = x1[0];\n xExtentDomain = [x0, x1];\n if (x.invert) x0 = x(x0), x1 = x(x1);\n if (x1 < x0) t = x0, x0 = x1, x1 = t;\n if (x0 != xExtent[0] || x1 != xExtent[1]) xExtent = [x0, x1]; // copy-on-write\n }\n\n if (y) {\n y0 = z[0], y1 = z[1];\n if (x) y0 = y0[1], y1 = y1[1];\n yExtentDomain = [y0, y1];\n if (y.invert) y0 = y(y0), y1 = y(y1);\n if (y1 < y0) t = y0, y0 = y1, y1 = t;\n if (y0 != yExtent[0] || y1 != yExtent[1]) yExtent = [y0, y1]; // copy-on-write\n }\n\n this.setState({\n xExtent: xExtent,\n yExtent: yExtent,\n xExtentDomain: xExtentDomain,\n yExtentDomain: yExtentDomain\n });\n },\n _empty: function _empty() {\n return !!this.props.xScale && this.state.xExtent[0] == this.state.xExtent[1] || !!this.props.yScale && this.state.yExtent[0] == this.state.yExtent[1];\n },\n // TODO: Code duplicated in Axis.jsx, move outside.\n _d3ScaleExtent: function _d3ScaleExtent(domain) {\n var start = domain[0];\n var stop = domain[domain.length - 1];\n return start < stop ? [start, stop] : [stop, start];\n },\n _d3ScaleRange: function _d3ScaleRange(scale) {\n return scale.rangeExtent ? scale.rangeExtent() : this._d3ScaleExtent(scale.range());\n }\n});\nvar _default = Brush;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/Brush.jsx?");
/***/ }),
/***/ "./src/Chart.jsx":
/*!***********************!*\
!*** ./src/Chart.jsx ***!
\***********************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar number = _propTypes.default.number,\n shape = _propTypes.default.shape;\nvar Chart = (0, _createReactClass.default)({\n displayName: \"Chart\",\n propTypes: {\n height: number.isRequired,\n width: number.isRequired,\n margin: shape({\n top: number,\n bottom: number,\n left: number,\n right: number\n }).isRequired\n },\n render: function render() {\n var _this$props = this.props,\n width = _this$props.width,\n height = _this$props.height,\n margin = _this$props.margin,\n viewBox = _this$props.viewBox,\n preserveAspectRatio = _this$props.preserveAspectRatio,\n children = _this$props.children;\n return _react.default.createElement(\"svg\", {\n ref: \"svg\",\n width: width,\n height: height,\n viewBox: viewBox,\n preserveAspectRatio: preserveAspectRatio\n }, _react.default.createElement(\"g\", {\n transform: \"translate(\".concat(margin.left, \", \").concat(margin.top, \")\")\n }, children));\n }\n});\nvar _default = Chart;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/Chart.jsx?");
/***/ }),
/***/ "./src/DefaultPropsMixin.jsx":
/*!***********************************!*\
!*** ./src/DefaultPropsMixin.jsx ***!
\***********************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _d = _interopRequireDefault(__webpack_require__(/*! d3 */ \"d3\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar oneOfType = _propTypes.default.oneOfType,\n object = _propTypes.default.object,\n array = _propTypes.default.array,\n shape = _propTypes.default.shape,\n func = _propTypes.default.func,\n number = _propTypes.default.number;\nvar DefaultPropsMixin = {\n propTypes: {\n data: oneOfType([object, array]).isRequired,\n height: number.isRequired,\n width: number.isRequired,\n margin: shape({\n top: number,\n bottom: number,\n left: number,\n right: number\n }),\n xScale: func,\n yScale: func,\n colorScale: func\n },\n getDefaultProps: function getDefaultProps() {\n return {\n data: {\n label: 'No data available',\n values: [{\n x: 'No data available',\n y: 1\n }]\n },\n margin: {\n top: 0,\n bottom: 0,\n left: 0,\n right: 0\n },\n xScale: null,\n yScale: null,\n colorScale: _d.default.scale.category20()\n };\n }\n};\nvar _default = DefaultPropsMixin;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/DefaultPropsMixin.jsx?");
/***/ }),
/***/ "./src/DefaultScalesMixin.jsx":
/*!************************************!*\
!*** ./src/DefaultScalesMixin.jsx ***!
\************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _d2 = _interopRequireDefault(__webpack_require__(/*! d3 */ \"d3\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }\n\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance\"); }\n\nfunction _iterableToArrayLimit(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\"] != null) _i[\"return\"](); } finally { if (_d) throw _e; } } return _arr; }\n\nfunction _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }\n\nvar number = _propTypes.default.number;\nvar DefaultScalesMixin = {\n propTypes: {\n barPadding: number\n },\n getDefaultProps: function getDefaultProps() {\n return {\n barPadding: 0.5\n };\n },\n componentWillMount: function componentWillMount() {\n this._makeScales(this.props);\n },\n componentWillReceiveProps: function componentWillReceiveProps(nextProps) {\n this._makeScales(nextProps);\n },\n _makeScales: function _makeScales(props) {\n var xScale = props.xScale,\n xIntercept = props.xIntercept,\n yScale = props.yScale,\n yIntercept = props.yIntercept;\n\n if (!xScale) {\n var _this$_makeXScale = this._makeXScale(props);\n\n var _this$_makeXScale2 = _slicedToArray(_this$_makeXScale, 2);\n\n this._xScale = _this$_makeXScale2[0];\n this._xIntercept = _this$_makeXScale2[1];\n } else {\n var _ref = [xScale, xIntercept];\n this._xScale = _ref[0];\n this._xIntercept = _ref[1];\n }\n\n if (!yScale) {\n var _this$_makeYScale = this._makeYScale(props);\n\n var _this$_makeYScale2 = _slicedToArray(_this$_makeYScale, 2);\n\n this._yScale = _this$_makeYScale2[0];\n this._yIntercept = _this$_makeYScale2[1];\n } else {\n var _ref2 = [yScale, yIntercept];\n this._yScale = _ref2[0];\n this._yIntercept = _ref2[1];\n }\n },\n _makeXScale: function _makeXScale(props) {\n var x = props.x,\n values = props.values;\n var data = this._data;\n\n if (typeof x(values(data[0])[0]) === 'number') {\n return this._makeLinearXScale(props);\n } else if (typeof x(values(data[0])[0]).getMonth === 'function') {\n return this._makeTimeXScale(props);\n } else {\n return this._makeOrdinalXScale(props);\n }\n },\n _makeLinearXScale: function _makeLinearXScale(props) {\n var x = props.x,\n values = props.values;\n var data = this._data;\n var extentsData = data.map(function (stack) {\n return values(stack).map(function (e) {\n return x(e);\n });\n });\n\n var extents = _d2.default.extent(Array.prototype.concat.apply([], extentsData));\n\n var scale = _d2.default.scale.linear().domain(extents).range([0, this._innerWidth]);\n\n var zero = _d2.default.max([0, scale.domain()[0]]);\n\n var xIntercept = scale(zero);\n return [scale, xIntercept];\n },\n _makeOrdinalXScale: function _makeOrdinalXScale(props) {\n var x = props.x,\n values = props.values,\n barPadding = props.barPadding;\n\n var scale = _d2.default.scale.ordinal().domain(values(this._data[0]).map(function (e) {\n return x(e);\n })).rangeRoundBands([0, this._innerWidth], barPadding);\n\n return [scale, 0];\n },\n _makeTimeXScale: function _makeTimeXScale(props) {\n var x = props.x,\n values = props.values;\n\n var minDate = _d2.default.min(values(this._data[0]), x);\n\n var maxDate = _d2.default.max(values(this._data[0]), x);\n\n var scale = _d2.default.time.scale().domain([minDate, maxDate]).range([0, this._innerWidth]);\n\n return [scale, 0];\n },\n _makeYScale: function _makeYScale(props) {\n var y = props.y,\n values = props.values;\n var data = this._data;\n\n if (typeof y(values(data[0])[0]) === 'number') {\n return this._makeLinearYScale(props);\n } else {\n return this._makeOrdinalYScale(props);\n }\n },\n _makeLinearYScale: function _makeLinearYScale(props) {\n var y = props.y,\n y0 = props.y0,\n values = props.values,\n groupedBars = props.groupedBars;\n\n var extentsData = this._data.map(function (stack) {\n return values(stack).map(function (e) {\n return groupedBars ? y(e) : y0(e) + y(e);\n });\n });\n\n var extents = _d2.default.extent(Array.prototype.concat.apply([], extentsData));\n\n extents = [_d2.default.min([0, extents[0]]), extents[1]];\n\n var scale = _d2.default.scale.linear().domain(extents).range([this._innerHeight, 0]);\n\n var zero = _d2.default.max([0, scale.domain()[0]]);\n\n var yIntercept = scale(zero);\n return [scale, yIntercept];\n },\n _makeOrdinalYScale: function _makeOrdinalYScale() {\n var scale = _d2.default.scale.ordinal().range([this._innerHeight, 0]);\n\n var yIntercept = scale(0);\n return [scale, yIntercept];\n }\n};\nvar _default = DefaultScalesMixin;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/DefaultScalesMixin.jsx?");
/***/ }),
/***/ "./src/HeightWidthMixin.jsx":
/*!**********************************!*\
!*** ./src/HeightWidthMixin.jsx ***!
\**********************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\nvar HeightWidthMixin = {\n componentWillMount: function componentWillMount() {\n this._calculateInner(this.props);\n },\n componentWillReceiveProps: function componentWillReceiveProps(nextProps) {\n this._calculateInner(nextProps);\n },\n _calculateInner: function _calculateInner(props) {\n var height = props.height,\n width = props.width,\n margin = props.margin;\n this._innerHeight = height - margin.top - margin.bottom;\n this._innerWidth = width - margin.left - margin.right;\n }\n};\nvar _default = HeightWidthMixin;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/HeightWidthMixin.jsx?");
/***/ }),
/***/ "./src/LineChart.jsx":
/*!***************************!*\
!*** ./src/LineChart.jsx ***!
\***************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nvar _d = _interopRequireDefault(__webpack_require__(/*! d3 */ \"d3\"));\n\nvar _Chart = _interopRequireDefault(__webpack_require__(/*! ./Chart */ \"./src/Chart.jsx\"));\n\nvar _Axis = _interopRequireDefault(__webpack_require__(/*! ./Axis */ \"./src/Axis.jsx\"));\n\nvar _Path = _interopRequireDefault(__webpack_require__(/*! ./Path */ \"./src/Path.jsx\"));\n\nvar _Tooltip = _interopRequireDefault(__webpack_require__(/*! ./Tooltip */ \"./src/Tooltip.jsx\"));\n\nvar _DefaultPropsMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultPropsMixin */ \"./src/DefaultPropsMixin.jsx\"));\n\nvar _HeightWidthMixin = _interopRequireDefault(__webpack_require__(/*! ./HeightWidthMixin */ \"./src/HeightWidthMixin.jsx\"));\n\nvar _ArrayifyMixin = _interopRequireDefault(__webpack_require__(/*! ./ArrayifyMixin */ \"./src/ArrayifyMixin.jsx\"));\n\nvar _AccessorMixin = _interopRequireDefault(__webpack_require__(/*! ./AccessorMixin */ \"./src/AccessorMixin.jsx\"));\n\nvar _DefaultScalesMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultScalesMixin */ \"./src/DefaultScalesMixin.jsx\"));\n\nvar _TooltipMixin = _interopRequireDefault(__webpack_require__(/*! ./TooltipMixin */ \"./src/TooltipMixin.jsx\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _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; }; return _extends.apply(this, arguments); }\n\nvar array = _propTypes.default.array,\n func = _propTypes.default.func,\n string = _propTypes.default.string;\nvar DataSet = (0, _createReactClass.default)({\n displayName: \"DataSet\",\n propTypes: {\n data: array.isRequired,\n line: func.isRequired,\n colorScale: func.isRequired\n },\n render: function render() {\n var _this$props = this.props,\n width = _this$props.width,\n height = _this$props.height,\n data = _this$props.data,\n line = _this$props.line,\n strokeWidth = _this$props.strokeWidth,\n strokeLinecap = _this$props.strokeLinecap,\n strokeDasharray = _this$props.strokeDasharray,\n colorScale = _this$props.colorScale,\n values = _this$props.values,\n label = _this$props.label,\n onMouseEnter = _this$props.onMouseEnter,\n _onMouseLeave = _this$props.onMouseLeave;\n var sizeId = width + 'x' + height;\n var lines = data.map(function (stack, index) {\n return _react.default.createElement(_Path.default, {\n key: \"\".concat(label(stack), \".\").concat(index),\n className: 'line',\n d: line(values(stack)),\n stroke: colorScale(label(stack)),\n strokeWidth: typeof strokeWidth === 'function' ? strokeWidth(label(stack)) : strokeWidth,\n strokeLinecap: typeof strokeLinecap === 'function' ? strokeLinecap(label(stack)) : strokeLinecap,\n strokeDasharray: typeof strokeDasharray === 'function' ? strokeDasharray(label(stack)) : strokeDasharray,\n data: values(stack),\n onMouseEnter: onMouseEnter,\n onMouseLeave: _onMouseLeave,\n style: {\n clipPath: \"url(#lineClip_\".concat(sizeId, \")\")\n }\n });\n });\n /*\n The <rect> below is needed in case we want to show the tooltip no matter where on the chart the mouse is.\n Not sure if this should be used.\n */\n\n return _react.default.createElement(\"g\", null, _react.default.createElement(\"defs\", null, _react.default.createElement(\"clipPath\", {\n id: \"lineClip_\".concat(sizeId)\n }, _react.default.createElement(\"rect\", {\n width: width,\n height: height\n }))), lines, _react.default.createElement(\"rect\", {\n width: width,\n height: height,\n fill: 'none',\n stroke: 'none',\n style: {\n pointerEvents: 'all'\n },\n onMouseMove: function onMouseMove(evt) {\n onMouseEnter(evt, data);\n },\n onMouseLeave: function onMouseLeave(evt) {\n _onMouseLeave(evt);\n }\n }));\n }\n});\nvar LineChart = (0, _createReactClass.default)({\n displayName: \"LineChart\",\n mixins: [_DefaultPropsMixin.default, _HeightWidthMixin.default, _ArrayifyMixin.default, _AccessorMixin.default, _DefaultScalesMixin.default, _TooltipMixin.default],\n propTypes: {\n interpolate: string,\n defined: func\n },\n getDefaultProps: function getDefaultProps() {\n return {\n interpolate: 'linear',\n defined: function defined() {\n return true;\n },\n shape: 'circle',\n shapeColor: null,\n showCustomLine: false,\n lineStructureClassName: 'dot',\n customPointColor: 'blue',\n customPointShape: 'circle'\n };\n },\n\n /*\n The code below supports finding the data values for the line closest to the mouse cursor.\n Since it gets all events from the Rect overlaying the Chart the tooltip gets shown everywhere.\n For now I don't want to use this method.\n */\n _tooltipHtml: function _tooltipHtml(data, position) {\n var _this$props2 = this.props,\n x = _this$props2.x,\n y = _this$props2.y,\n values = _this$props2.values,\n label = _this$props2.label;\n var xScale = this._xScale;\n var yScale = this._yScale;\n var xValueCursor = xScale.invert(position[0]);\n var yValueCursor = yScale.invert(position[1]);\n\n var xBisector = _d.default.bisector(function (e) {\n return x(e);\n }).left;\n\n var valuesAtX = data.map(function (stack) {\n var idx = xBisector(values(stack), xValueCursor);\n var indexRight = idx === values(stack).length ? idx - 1 : idx;\n var valueRight = x(values(stack)[indexRight]);\n var indexLeft = idx === 0 ? idx : idx - 1;\n var valueLeft = x(values(stack)[indexLeft]);\n var index;\n\n if (Math.abs(xValueCursor - valueRight) < Math.abs(xValueCursor - valueLeft)) {\n index = indexRight;\n } else {\n index = indexLeft;\n }\n\n return {\n label: label(stack),\n value: values(stack)[index]\n };\n });\n valuesAtX.sort(function (a, b) {\n return y(a.value) - y(b.value);\n });\n\n var yBisector = _d.default.bisector(function (e) {\n return y(e.value);\n }).left;\n\n var yIndex = yBisector(valuesAtX, yValueCursor);\n var yIndexRight = yIndex === valuesAtX.length ? yIndex - 1 : yIndex;\n var yIndexLeft = yIndex === 0 ? yIndex : yIndex - 1;\n var yValueRight = y(valuesAtX[yIndexRight].value);\n var yValueLeft = y(valuesAtX[yIndexLeft].value);\n var index;\n\n if (Math.abs(yValueCursor - yValueRight) < Math.abs(yValueCursor - yValueLeft)) {\n index = yIndexRight;\n } else {\n index = yIndexLeft;\n }\n\n this._tooltipData = valuesAtX[index];\n var html = this.props.tooltipHtml(valuesAtX[index].label, valuesAtX[index].value);\n var xPos = xScale(valuesAtX[index].value.x);\n var yPos = yScale(valuesAtX[index].value.y);\n return [html, xPos, yPos];\n },\n\n /*\n _tooltipHtml(data, position) {\n let {x, y0, y, values, label} = this.props;\n let [xScale, yScale] = [this._xScale, this._yScale];\n let xValueCursor = xScale.invert(position[0]);\n let yValueCursor = yScale.invert(position[1]);\n let xBisector = d3.bisector(e => { return x(e); }).left;\n let xIndex = xBisector(data, xScale.invert(position[0]));\n let indexRight = xIndex == data.length ? xIndex - 1 : xIndex;\n let valueRight = x(data[indexRight]);\n let indexLeft = xIndex == 0 ? xIndex : xIndex - 1;\n let valueLeft = x(data[indexLeft]);\n let index;\n if (Math.abs(xValueCursor - valueRight) < Math.abs(xValueCursor - valueLeft)) {\n index = indexRight;\n } else {\n index = indexLeft;\n }\n let yValue = y(data[index]);\n let cursorValue = d3.round(yScale.invert(position[1]), 2);\n return this.props.tooltipHtml(yValue, cursorValue);\n },\n */\n\n /*\n stroke,\n strokeWidth,\n strokeLinecap,\n strokeDasharray,\n */\n render: function render() {\n var _this = this;\n\n var _this$props3 = this.props,\n height = _this$props3.height,\n width = _this$props3.width,\n margin = _this$props3.margin,\n viewBox = _this$props3.viewBox,\n preserveAspectRatio = _this$props3.preserveAspectRatio,\n colorScale = _this$props3.colorScale,\n interpolate = _this$props3.interpolate,\n defined = _this$props3.defined,\n stroke = _this$props3.stroke,\n values = _this$props3.values,\n label = _this$props3.label,\n x = _this$props3.x,\n y = _this$props3.y,\n xAxis = _this$props3.xAxis,\n yAxis = _this$props3.yAxis,\n shape = _this$props3.shape,\n shapeColor = _this$props3.shapeColor,\n showCustomLine = _this$props3.showCustomLine,\n lineStructureClassName = _this$props3.lineStructureClassName,\n customPointColor = _this$props3.customPointColor,\n customPointShape = _this$props3.customPointShape;\n var data = this._data;\n var innerWidth = this._innerWidth;\n var innerHeight = this._innerHeight;\n var xScale = this._xScale;\n var yScale = this._yScale;\n var xIntercept = this._xIntercept;\n var yIntercept = this._yIntercept;\n\n var line = _d.default.svg.line().x(function (e) {\n return xScale(x(e));\n }).y(function (e) {\n return yScale(y(e));\n }).interpolate(interpolate).defined(defined);\n\n var tooltipSymbol = null,\n points = null;\n\n if (!this.state.tooltip.hidden) {\n var symbol = _d.default.svg.symbol().type(shape);\n\n var symbolColor = shapeColor ? shapeColor : colorScale(this._tooltipData.label);\n var translate = this._tooltipData ? \"translate(\".concat(xScale(x(this._tooltipData.value)), \", \").concat(yScale(y(this._tooltipData.value)), \")\") : '';\n tooltipSymbol = this.state.tooltip.hidden ? null : _react.default.createElement(\"path\", {\n className: \"dot\",\n d: symbol(),\n transform: translate,\n fill: symbolColor,\n onMouseEnter: function onMouseEnter(evt) {\n return _this.onMouseEnter(evt, data);\n },\n onMouseLeave: function onMouseLeave(evt) {\n return _this.onMouseLeave(evt);\n }\n });\n }\n\n if (showCustomLine) {\n var translatePoints = function translatePoints(point) {\n return \"translate(\".concat(xScale(x(point)), \", \").concat(yScale(y(point)), \")\");\n };\n\n points = data.map(function (d) {\n return d.values.map(function (p, i) {\n return _react.default.createElement(\"path\", {\n key: i,\n className: lineStructureClassName,\n d: _d.default.svg.symbol().type(customPointShape)(),\n transform: translatePoints(p),\n fill: customPointColor,\n onMouseEnter: function onMouseEnter(evt) {\n return _this.onMouseEnter(evt, data);\n },\n onMouseLeave: function onMouseLeave(evt) {\n return _this.onMouseLeave(evt);\n }\n });\n });\n });\n }\n\n return _react.default.createElement(\"div\", null, _react.default.createElement(_Chart.default, {\n height: height,\n width: width,\n margin: margin,\n viewBox: viewBox,\n preserveAspectRatio: preserveAspectRatio\n }, _react.default.createElement(_Axis.default, _extends({\n className: \"x axis\",\n orientation: \"bottom\",\n scale: xScale,\n height: innerHeight,\n width: innerWidth,\n zero: yIntercept\n }, xAxis)), _react.default.createElement(_Axis.default, _extends({\n className: \"y axis\",\n orientation: \"left\",\n scale: yScale,\n height: innerHeight,\n width: innerWidth,\n zero: xIntercept\n }, yAxis)), _react.default.createElement(DataSet, _extends({\n height: innerHeight,\n width: innerWidth,\n data: data,\n line: line,\n colorScale: colorScale,\n values: values,\n label: label,\n onMouseEnter: this.onMouseEnter,\n onMouseLeave: this.onMouseLeave\n }, stroke)), this.props.children, tooltipSymbol, points), _react.default.createElement(_Tooltip.default, this.state.tooltip));\n }\n});\nvar _default = LineChart;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/LineChart.jsx?");
/***/ }),
/***/ "./src/Path.jsx":
/*!**********************!*\
!*** ./src/Path.jsx ***!
\**********************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar string = _propTypes.default.string,\n array = _propTypes.default.array;\nvar Path = (0, _createReactClass.default)({\n displayName: \"Path\",\n propTypes: {\n className: string,\n stroke: string.isRequired,\n strokeLinecap: string,\n strokeWidth: string,\n strokeDasharray: string,\n fill: string,\n d: string.isRequired,\n data: array.isRequired\n },\n getDefaultProps: function getDefaultProps() {\n return {\n className: 'path',\n fill: 'none',\n strokeWidth: '2',\n strokeLinecap: 'butt',\n strokeDasharray: 'none'\n };\n },\n render: function render() {\n var _this$props = this.props,\n className = _this$props.className,\n stroke = _this$props.stroke,\n strokeWidth = _this$props.strokeWidth,\n strokeLinecap = _this$props.strokeLinecap,\n strokeDasharray = _this$props.strokeDasharray,\n fill = _this$props.fill,\n d = _this$props.d,\n style = _this$props.style,\n data = _this$props.data,\n onMouseEnter = _this$props.onMouseEnter,\n _onMouseLeave = _this$props.onMouseLeave;\n return _react.default.createElement(\"path\", {\n className: className,\n stroke: stroke,\n strokeWidth: strokeWidth,\n strokeLinecap: strokeLinecap,\n strokeDasharray: strokeDasharray,\n fill: fill,\n d: d,\n onMouseMove: function onMouseMove(evt) {\n return onMouseEnter(evt, data);\n },\n onMouseLeave: function onMouseLeave(evt) {\n return _onMouseLeave(evt);\n },\n style: style\n });\n }\n});\nvar _default = Path;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/Path.jsx?");
/***/ }),
/***/ "./src/PieChart.jsx":
/*!**************************!*\
!*** ./src/PieChart.jsx ***!
\**************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nvar _d = _interopRequireDefault(__webpack_require__(/*! d3 */ \"d3\"));\n\nvar _Chart = _interopRequireDefault(__webpack_require__(/*! ./Chart */ \"./src/Chart.jsx\"));\n\nvar _Tooltip = _interopRequireDefault(__webpack_require__(/*! ./Tooltip */ \"./src/Tooltip.jsx\"));\n\nvar _DefaultPropsMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultPropsMixin */ \"./src/DefaultPropsMixin.jsx\"));\n\nvar _HeightWidthMixin = _interopRequireDefault(__webpack_require__(/*! ./HeightWidthMixin */ \"./src/HeightWidthMixin.jsx\"));\n\nvar _AccessorMixin = _interopRequireDefault(__webpack_require__(/*! ./AccessorMixin */ \"./src/AccessorMixin.jsx\"));\n\nvar _TooltipMixin = _interopRequireDefault(__webpack_require__(/*! ./TooltipMixin */ \"./src/TooltipMixin.jsx\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar string = _propTypes.default.string,\n array = _propTypes.default.array,\n number = _propTypes.default.number,\n bool = _propTypes.default.bool,\n func = _propTypes.default.func,\n any = _propTypes.default.any;\nvar Wedge = (0, _createReactClass.default)({\n displayName: \"Wedge\",\n propTypes: {\n d: string.isRequired,\n fill: string.isRequired\n },\n render: function render() {\n var _this$props = this.props,\n fill = _this$props.fill,\n d = _this$props.d,\n data = _this$props.data,\n onMouseEnter = _this$props.onMouseEnter,\n _onMouseLeave = _this$props.onMouseLeave;\n return _react.default.createElement(\"path\", {\n fill: fill,\n d: d,\n onMouseMove: function onMouseMove(evt) {\n return onMouseEnter(evt, data);\n },\n onMouseLeave: function onMouseLeave(evt) {\n return _onMouseLeave(evt);\n }\n });\n }\n});\nvar DataSet = (0, _createReactClass.default)({\n displayName: \"DataSet\",\n propTypes: {\n pie: array.isRequired,\n arc: func.isRequired,\n outerArc: func.isRequired,\n colorScale: func.isRequired,\n radius: number.isRequired,\n strokeWidth: number,\n stroke: string,\n fill: string,\n opacity: number,\n x: func.isRequired,\n hideLabels: bool\n },\n getDefaultProps: function getDefaultProps() {\n return {\n strokeWidth: 2,\n stroke: '#000',\n fill: 'none',\n opacity: 0.3,\n hideLabels: false\n };\n },\n renderLabel: function renderLabel(wedge) {\n var _this$props2 = this.props,\n arc = _this$props2.arc,\n outerArc = _this$props2.outerArc,\n radius = _this$props2.radius,\n strokeWidth = _this$props2.strokeWidth,\n stroke = _this$props2.stroke,\n fill = _this$props2.fill,\n opacity = _this$props2.opacity,\n x = _this$props2.x;\n var labelPos = outerArc.centroid(wedge);\n labelPos[0] = radius * (this.midAngle(wedge) < Math.PI ? 1 : -1);\n var linePos = outerArc.centroid(wedge);\n linePos[0] = radius * 0.95 * (this.midAngle(wedge) < Math.PI ? 1 : -1);\n var textAnchor = this.midAngle(wedge) < Math.PI ? 'start' : 'end';\n return _react.default.createElement(\"g\", null, _react.default.createElement(\"polyline\", {\n opacity: opacity,\n strokeWidth: strokeWidth,\n stroke: stroke,\n fill: fill,\n points: [arc.centroid(wedge), outerArc.centroid(wedge), linePos]\n }), _react.default.createElement(\"text\", {\n dy: \".35em\",\n x: labelPos[0],\n y: labelPos[1],\n textAnchor: textAnchor\n }, x(wedge.data)));\n },\n render: function render() {\n var _this = this;\n\n var _this$props3 = this.props,\n pie = _this$props3.pie,\n arc = _this$props3.arc,\n colorScale = _this$props3.colorScale,\n x = _this$props3.x,\n y = _this$props3.y,\n onMouseEnter = _this$props3.onMouseEnter,\n onMouseLeave = _this$props3.onMouseLeave,\n hideLabels = _this$props3.hideLabels;\n var wedges = pie.map(function (e, index) {\n var labelFits = e.endAngle - e.startAngle >= 10 * Math.PI / 180;\n return _react.default.createElement(\"g\", {\n key: \"\".concat(x(e.data), \".\").concat(y(e.data), \".\").concat(index),\n className: \"arc\"\n }, _react.default.createElement(Wedge, {\n data: e.data,\n fill: colorScale(x(e.data)),\n d: arc(e),\n onMouseEnter: onMouseEnter,\n onMouseLeave: onMouseLeave\n }), !hideLabels && !!e.value && labelFits && _this.renderLabel(e));\n });\n return _react.default.createElement(\"g\", null, wedges);\n },\n midAngle: function midAngle(d) {\n return d.startAngle + (d.endAngle - d.startAngle) / 2;\n }\n});\nvar PieChart = (0, _createReactClass.default)({\n displayName: \"PieChart\",\n mixins: [_DefaultPropsMixin.default, _HeightWidthMixin.default, _AccessorMixin.default, _TooltipMixin.default],\n propTypes: {\n innerRadius: number,\n outerRadius: number,\n labelRadius: number,\n padRadius: string,\n cornerRadius: number,\n sort: any,\n hideLabels: bool\n },\n getDefaultProps: function getDefaultProps() {\n return {\n innerRadius: null,\n outerRadius: null,\n labelRadius: null,\n padRadius: 'auto',\n cornerRadius: 0,\n sort: undefined,\n hideLabels: false\n };\n },\n _tooltipHtml: function _tooltipHtml(d) {\n var html = this.props.tooltipHtml(this.props.x(d), this.props.y(d));\n return [html, 0, 0];\n },\n render: function render() {\n var _this$props4 = this.props,\n data = _this$props4.data,\n width = _this$props4.width,\n height = _this$props4.height,\n margin = _this$props4.margin,\n viewBox = _this$props4.viewBox,\n preserveAspectRatio = _this$props4.preserveAspectRatio,\n colorScale = _this$props4.colorScale,\n padRadius = _this$props4.padRadius,\n cornerRadius = _this$props4.cornerRadius,\n sort = _this$props4.sort,\n x = _this$props4.x,\n y = _this$props4.y,\n values = _this$props4.values,\n hideLabels = _this$props4.hideLabels;\n var _this$props5 = this.props,\n innerRadius = _this$props5.innerRadius,\n outerRadius = _this$props5.outerRadius,\n labelRadius = _this$props5.labelRadius;\n var innerWidth = this._innerWidth;\n var innerHeight = this._innerHeight;\n\n var pie = _d.default.layout.pie().value(function (e) {\n return y(e);\n });\n\n if (typeof sort !== 'undefined') {\n pie = pie.sort(sort);\n }\n\n var radius = Math.min(innerWidth, innerHeight) / 2;\n\n if (!innerRadius) {\n innerRadius = radius * 0.8;\n }\n\n if (!outerRadius) {\n outerRadius = radius * 0.4;\n }\n\n if (!labelRadius) {\n labelRadius = radius * 0.9;\n }\n\n var arc = _d.default.svg.arc().innerRadius(innerRadius).outerRadius(outerRadius).padRadius(padRadius).cornerRadius(cornerRadius);\n\n var outerArc = _d.default.svg.arc().innerRadius(labelRadius).outerRadius(labelRadius);\n\n var pieData = pie(values(data));\n var translation = \"translate(\".concat(innerWidth / 2, \", \").concat(innerHeight / 2, \")\");\n return _react.default.createElement(\"div\", null, _react.default.createElement(_Chart.default, {\n height: height,\n width: width,\n margin: margin,\n viewBox: viewBox,\n preserveAspectRatio: preserveAspectRatio\n }, _react.default.createElement(\"g\", {\n transform: translation\n }, _react.default.createElement(DataSet, {\n width: innerWidth,\n height: innerHeight,\n colorScale: colorScale,\n pie: pieData,\n arc: arc,\n outerArc: outerArc,\n radius: radius,\n x: x,\n y: y,\n onMouseEnter: this.onMouseEnter,\n onMouseLeave: this.onMouseLeave,\n hideLabels: hideLabels\n })), this.props.children), _react.default.createElement(_Tooltip.default, this.state.tooltip));\n }\n});\nvar _default = PieChart;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/PieChart.jsx?");
/***/ }),
/***/ "./src/ScatterPlot.jsx":
/*!*****************************!*\
!*** ./src/ScatterPlot.jsx ***!
\*****************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nvar _d = _interopRequireDefault(__webpack_require__(/*! d3 */ \"d3\"));\n\nvar _Chart = _interopRequireDefault(__webpack_require__(/*! ./Chart */ \"./src/Chart.jsx\"));\n\nvar _Axis = _interopRequireDefault(__webpack_require__(/*! ./Axis */ \"./src/Axis.jsx\"));\n\nvar _Tooltip = _interopRequireDefault(__webpack_require__(/*! ./Tooltip */ \"./src/Tooltip.jsx\"));\n\nvar _DefaultPropsMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultPropsMixin */ \"./src/DefaultPropsMixin.jsx\"));\n\nvar _HeightWidthMixin = _interopRequireDefault(__webpack_require__(/*! ./HeightWidthMixin */ \"./src/HeightWidthMixin.jsx\"));\n\nvar _ArrayifyMixin = _interopRequireDefault(__webpack_require__(/*! ./ArrayifyMixin */ \"./src/ArrayifyMixin.jsx\"));\n\nvar _AccessorMixin = _interopRequireDefault(__webpack_require__(/*! ./AccessorMixin */ \"./src/AccessorMixin.jsx\"));\n\nvar _DefaultScalesMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultScalesMixin */ \"./src/DefaultScalesMixin.jsx\"));\n\nvar _TooltipMixin = _interopRequireDefault(__webpack_require__(/*! ./TooltipMixin */ \"./src/TooltipMixin.jsx\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _extends() { _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; }; return _extends.apply(this, arguments); }\n\nvar array = _propTypes.default.array,\n func = _propTypes.default.func,\n string = _propTypes.default.string;\nvar DataSet = (0, _createReactClass.default)({\n displayName: \"DataSet\",\n propTypes: {\n data: array.isRequired,\n symbol: func.isRequired,\n xScale: func.isRequired,\n yScale: func.isRequired,\n colorScale: func.isRequired,\n onMouseEnter: func,\n onMouseLeave: func\n },\n render: function render() {\n var _this$props = this.props,\n data = _this$props.data,\n symbol = _this$props.symbol,\n xScale = _this$props.xScale,\n yScale = _this$props.yScale,\n colorScale = _this$props.colorScale,\n label = _this$props.label,\n values = _this$props.values,\n x = _this$props.x,\n y = _this$props.y,\n onMouseEnter = _this$props.onMouseEnter,\n _onMouseLeave = _this$props.onMouseLeave;\n var circles = data.map(function (stack) {\n return values(stack).map(function (e, index) {\n var translate = \"translate(\".concat(xScale(x(e)), \", \").concat(yScale(y(e)), \")\");\n return _react.default.createElement(\"path\", {\n key: \"\".concat(label(stack), \".\").concat(index),\n className: \"dot\",\n d: symbol(),\n transform: translate,\n fill: colorScale(label(stack)),\n onMouseOver: function onMouseOver(evt) {\n return onMouseEnter(evt, e);\n },\n onMouseLeave: function onMouseLeave(evt) {\n return _onMouseLeave(evt);\n }\n });\n });\n });\n return _react.default.createElement(\"g\", null, circles);\n }\n});\nvar ScatterPlot = (0, _createReactClass.default)({\n displayName: \"ScatterPlot\",\n mixins: [_DefaultPropsMixin.default, _HeightWidthMixin.default, _ArrayifyMixin.default, _AccessorMixin.default, _DefaultScalesMixin.default, _TooltipMixin.default],\n propTypes: {\n rScale: func,\n shape: string\n },\n getDefaultProps: function getDefaultProps() {\n return {\n rScale: null,\n shape: 'circle'\n };\n },\n _tooltipHtml: function _tooltipHtml(d) {\n var html = this.props.tooltipHtml(this.props.x(d), this.props.y(d));\n\n var xPos = this._xScale(this.props.x(d));\n\n var yPos = this._yScale(this.props.y(d));\n\n return [html, xPos, yPos];\n },\n render: function render() {\n var _this$props2 = this.props,\n height = _this$props2.height,\n width = _this$props2.width,\n margin = _this$props2.margin,\n viewBox = _this$props2.viewBox,\n preserveAspectRatio = _this$props2.preserveAspectRatio,\n colorScale = _this$props2.colorScale,\n rScale = _this$props2.rScale,\n shape = _this$props2.shape,\n label = _this$props2.label,\n values = _this$props2.values,\n x = _this$props2.x,\n y = _this$props2.y,\n xAxis = _this$props2.xAxis,\n yAxis = _this$props2.yAxis;\n var data = this._data;\n var innerWidth = this._innerWidth;\n var innerHeight = this._innerHeight;\n var xScale = this._xScale;\n var yScale = this._yScale;\n var xIntercept = this._xIntercept;\n var yIntercept = this._yIntercept;\n\n var symbol = _d.default.svg.symbol().type(shape);\n\n if (rScale) {\n symbol = symbol.size(rScale);\n }\n\n return _react.default.createElement(\"div\", null, _react.default.createElement(_Chart.default, {\n height: height,\n width: width,\n margin: margin,\n viewBox: viewBox,\n preserveAspectRatio: preserveAspectRatio\n }, _react.default.createElement(_Axis.default, _extends({\n className: \"x axis\",\n orientation: \"bottom\",\n scale: xScale,\n height: innerHeight,\n width: innerWidth,\n zero: yIntercept\n }, xAxis)), _react.default.createElement(_Axis.default, _extends({\n className: \"y axis\",\n orientation: \"left\",\n scale: yScale,\n height: innerHeight,\n width: innerWidth,\n zero: xIntercept\n }, yAxis)), _react.default.createElement(DataSet, {\n data: data,\n xScale: xScale,\n yScale: yScale,\n colorScale: colorScale,\n symbol: symbol,\n label: label,\n values: values,\n x: x,\n y: y,\n onMouseEnter: this.onMouseEnter,\n onMouseLeave: this.onMouseLeave\n }), this.props.children), _react.default.createElement(_Tooltip.default, this.state.tooltip));\n }\n});\nvar _default = ScatterPlot;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/ScatterPlot.jsx?");
/***/ }),
/***/ "./src/StackAccessorMixin.jsx":
/*!************************************!*\
!*** ./src/StackAccessorMixin.jsx ***!
\************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar func = _propTypes.default.func;\nvar StackAccessorMixin = {\n propTypes: {\n label: func,\n values: func,\n x: func,\n y: func,\n y0: func\n },\n getDefaultProps: function getDefaultProps() {\n return {\n label: function label(stack) {\n return stack.label;\n },\n values: function values(stack) {\n return stack.values;\n },\n x: function x(e) {\n return e.x;\n },\n y: function y(e) {\n return e.y;\n },\n y0: function y0(e) {\n return e.y0;\n }\n };\n }\n};\nvar _default = StackAccessorMixin;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/StackAccessorMixin.jsx?");
/***/ }),
/***/ "./src/StackDataMixin.jsx":
/*!********************************!*\
!*** ./src/StackDataMixin.jsx ***!
\********************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _d = _interopRequireDefault(__webpack_require__(/*! d3 */ \"d3\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar string = _propTypes.default.string;\nvar StackDataMixin = {\n propTypes: {\n offset: string\n },\n getDefaultProps: function getDefaultProps() {\n return {\n offset: 'zero',\n order: 'default'\n };\n },\n componentWillMount: function componentWillMount() {\n this._stackData(this.props);\n },\n componentWillReceiveProps: function componentWillReceiveProps(nextProps) {\n this._stackData(nextProps);\n },\n _stackData: function _stackData(props) {\n var offset = props.offset,\n order = props.order,\n x = props.x,\n y = props.y,\n values = props.values;\n\n var stack = _d.default.layout.stack().offset(offset).order(order).x(x).y(y).values(values);\n\n this._data = stack(this._data);\n\n for (var m = 0; m < values(this._data[0]).length; m++) {\n var positiveBase = 0;\n var negativeBase = 0;\n\n for (var n = 0; n < this._data.length; n++) {\n var value = y(values(this._data[n])[m]);\n\n if (value < 0) {\n values(this._data[n])[m].y0 = negativeBase;\n negativeBase += value;\n } else {\n values(this._data[n])[m].y0 = positiveBase;\n positiveBase += value;\n }\n }\n }\n }\n};\nvar _default = StackDataMixin;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/StackDataMixin.jsx?");
/***/ }),
/***/ "./src/Tooltip.jsx":
/*!*************************!*\
!*** ./src/Tooltip.jsx ***!
\*************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar number = _propTypes.default.number,\n node = _propTypes.default.node;\nvar Tooltip = (0, _createReactClass.default)({\n displayName: \"Tooltip\",\n propTypes: {\n top: number.isRequired,\n left: number.isRequired,\n html: node,\n translate: number\n },\n getDefaultProps: function getDefaultProps() {\n return {\n top: 150,\n left: 100,\n html: '',\n translate: 50\n };\n },\n render: function render() {\n var _this$props = this.props,\n top = _this$props.top,\n left = _this$props.left,\n hidden = _this$props.hidden,\n html = _this$props.html,\n translate = _this$props.translate;\n var style = {\n display: hidden ? 'none' : 'block',\n position: 'fixed',\n top: top,\n left: left,\n transform: \"translate(-\".concat(translate, \"%, 0)\"),\n pointerEvents: 'none'\n };\n return _react.default.createElement(\"div\", {\n className: \"tooltip\",\n style: style\n }, html);\n }\n});\nvar _default = Tooltip;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/Tooltip.jsx?");
/***/ }),
/***/ "./src/TooltipMixin.jsx":
/*!******************************!*\
!*** ./src/TooltipMixin.jsx ***!
\******************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _reactDom = _interopRequireDefault(__webpack_require__(/*! react-dom */ \"react-dom\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }\n\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance\"); }\n\nfunction _iterableToArrayLimit(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\"] != null) _i[\"return\"](); } finally { if (_d) throw _e; } } return _arr; }\n\nfunction _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }\n\nvar func = _propTypes.default.func,\n oneOf = _propTypes.default.oneOf,\n bool = _propTypes.default.bool,\n objectOf = _propTypes.default.objectOf,\n number = _propTypes.default.number;\nvar TooltipMixin = {\n propTypes: {\n tooltipHtml: func,\n tooltipMode: oneOf(['mouse', 'element', 'fixed']),\n tooltipContained: bool,\n tooltipOffset: objectOf(number)\n },\n getInitialState: function getInitialState() {\n return {\n tooltip: {\n hidden: true\n }\n };\n },\n getDefaultProps: function getDefaultProps() {\n return {\n tooltipMode: 'mouse',\n tooltipOffset: {\n top: -35,\n left: 0\n },\n tooltipHtml: null,\n tooltipContained: false\n };\n },\n componentDidMount: function componentDidMount() {\n this._svgNode = _reactDom.default.findDOMNode(this).getElementsByTagName('svg')[0];\n },\n onMouseEnter: function onMouseEnter(e, data) {\n if (!this.props.tooltipHtml) {\n return;\n }\n\n e.preventDefault();\n var _this$props = this.props,\n margin = _this$props.margin,\n tooltipMode = _this$props.tooltipMode,\n tooltipOffset = _this$props.tooltipOffset,\n tooltipContained = _this$props.tooltipContained;\n var svg = this._svgNode;\n var position;\n\n if (svg.createSVGPoint) {\n var point = svg.createSVGPoint();\n point.x = e.clientX, point.y = e.clientY;\n point = point.matrixTransform(svg.getScreenCTM().inverse());\n position = [point.x - margin.left, point.y - margin.top];\n } else {\n var rect = svg.getBoundingClientRect();\n position = [e.clientX - rect.left - svg.clientLeft - margin.left, e.clientY - rect.top - svg.clientTop - margin.top];\n }\n\n var _this$_tooltipHtml = this._tooltipHtml(data, position),\n _this$_tooltipHtml2 = _slicedToArray(_this$_tooltipHtml, 3),\n html = _this$_tooltipHtml2[0],\n xPos = _this$_tooltipHtml2[1],\n yPos = _this$_tooltipHtml2[2];\n\n var svgTop = svg.getBoundingClientRect().top + margin.top;\n var svgLeft = svg.getBoundingClientRect().left + margin.left;\n var top = 0;\n var left = 0;\n\n if (tooltipMode === 'fixed') {\n top = svgTop + tooltipOffset.top;\n left = svgLeft + tooltipOffset.left;\n } else if (tooltipMode === 'element') {\n top = svgTop + yPos + tooltipOffset.top;\n left = svgLeft + xPos + tooltipOffset.left;\n } else {\n // mouse\n top = e.clientY + tooltipOffset.top;\n left = e.clientX + tooltipOffset.left;\n }\n\n function lerp(t, a, b) {\n return (1 - t) * a + t * b;\n }\n\n var translate = 50;\n\n if (tooltipContained) {\n var t = position[0] / svg.getBoundingClientRect().width;\n translate = lerp(t, 0, 100);\n }\n\n this.setState({\n tooltip: {\n top: top,\n left: left,\n hidden: false,\n html: html,\n translate: translate\n }\n });\n },\n onMouseLeave: function onMouseLeave(e) {\n if (!this.props.tooltipHtml) {\n return;\n }\n\n e.preventDefault();\n this.setState({\n tooltip: {\n hidden: true\n }\n });\n }\n};\nvar _default = TooltipMixin;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/TooltipMixin.jsx?");
/***/ }),
/***/ "./src/Waveform.jsx":
/*!**************************!*\
!*** ./src/Waveform.jsx ***!
\**************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _react = _interopRequireDefault(__webpack_require__(/*! react */ \"react\"));\n\nvar _propTypes = _interopRequireDefault(__webpack_require__(/*! prop-types */ \"./node_modules/prop-types/index.js\"));\n\nvar _createReactClass = _interopRequireDefault(__webpack_require__(/*! create-react-class */ \"./node_modules/create-react-class/index.js\"));\n\nvar _Chart = _interopRequireDefault(__webpack_require__(/*! ./Chart */ \"./src/Chart.jsx\"));\n\nvar _Bar = _interopRequireDefault(__webpack_require__(/*! ./Bar */ \"./src/Bar.jsx\"));\n\nvar _DefaultPropsMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultPropsMixin */ \"./src/DefaultPropsMixin.jsx\"));\n\nvar _HeightWidthMixin = _interopRequireDefault(__webpack_require__(/*! ./HeightWidthMixin */ \"./src/HeightWidthMixin.jsx\"));\n\nvar _ArrayifyMixin = _interopRequireDefault(__webpack_require__(/*! ./ArrayifyMixin */ \"./src/ArrayifyMixin.jsx\"));\n\nvar _StackAccessorMixin = _interopRequireDefault(__webpack_require__(/*! ./StackAccessorMixin */ \"./src/StackAccessorMixin.jsx\"));\n\nvar _StackDataMixin = _interopRequireDefault(__webpack_require__(/*! ./StackDataMixin */ \"./src/StackDataMixin.jsx\"));\n\nvar _DefaultScalesMixin = _interopRequireDefault(__webpack_require__(/*! ./DefaultScalesMixin */ \"./src/DefaultScalesMixin.jsx\"));\n\nvar _TooltipMixin = _interopRequireDefault(__webpack_require__(/*! ./TooltipMixin */ \"./src/TooltipMixin.jsx\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar array = _propTypes.default.array,\n func = _propTypes.default.func; // receive array and return a subsampled array of size n\n//\n// a= the array;\n// n= number of sample you want output\n\nvar subSample = function subSample(a, n) {\n var returnArray = [];\n var m = a.length;\n var samplingRatio = m / n; //just round down for now in case of comma separated\n\n for (var i = 0; i < m;) {\n returnArray.push(a[Math.floor(i)]);\n i += samplingRatio;\n }\n\n return returnArray;\n};\n\nvar DataSet = (0, _createReactClass.default)({\n displayName: \"DataSet\",\n propTypes: {\n data: array.isRequired,\n xScale: func.isRequired,\n yScale: func.isRequired,\n colorScale: func.isRequired,\n values: func.isRequired,\n label: func.isRequired,\n x: func.isRequired,\n y: func.isRequired,\n y0: func.isRequired\n },\n render: function render() {\n var _this$props = this.props,\n data = _this$props.data,\n yScale = _this$props.yScale,\n colorScale = _this$props.colorScale,\n values = _this$props.values,\n label = _this$props.label,\n y = _this$props.y,\n x0 = _this$props.x0,\n onMouseEnter = _this$props.onMouseEnter,\n onMouseLeave = _this$props.onMouseLeave;\n var height = yScale(yScale.domain()[0]);\n var bars = data.map(function (stack) {\n return values(stack).map(function (e, index) {\n // maps the range [0,1] to the range [0, yDomain]\n var yValue = height * y(e); // center vertically to have upper and lower part of the waveform\n\n var vy = height / 2 - yValue / 2; //position x(e) * width * 2 because we want equal sapce.\n\n var vx = 2 * x0 * index;\n return _react.default.createElement(_Bar.default, {\n key: \"\".concat(label(stack), \".\").concat(index),\n width: x0,\n height: yValue,\n x: vx,\n y: vy,\n fill: colorScale(Math.floor(vx)),\n data: e,\n onMouseEnter: onMouseEnter,\n onMouseLeave: onMouseLeave\n });\n });\n });\n return _react.default.createElement(\"g\", null, bars);\n }\n});\nvar Waveform = (0, _createReactClass.default)({\n displayName: \"Waveform\",\n mixins: [_DefaultPropsMixin.default, _HeightWidthMixin.default, _ArrayifyMixin.default, _StackAccessorMixin.default, _StackDataMixin.default, _DefaultScalesMixin.default, _TooltipMixin.default],\n getDefaultProps: function getDefaultProps() {\n return {};\n },\n _tooltipHtml: function _tooltipHtml(d) {\n var _ref = [this._xScale, this._yScale],\n xScale = _ref[0],\n yScale = _ref[1];\n var html = this.props.tooltipHtml(this.props.x(d), this.props.y0(d), this.props.y(d));\n var midPoint = xScale.rangeBand() / 2;\n var xPos = midPoint + xScale(this.props.x(d));\n var topStack = this._data[this._data.length - 1].values;\n var topElement = null; // TODO: this might not scale if dataset is huge.\n // consider pre-computing yPos for each X\n\n for (var i = 0; i < topStack.length; i++) {\n if (this.props.x(topStack[i]) === this.props.x(d)) {\n topElement = topStack[i];\n break;\n }\n }\n\n var yPos = yScale(this.props.y0(topElement) + this.props.y(topElement));\n return [html, xPos, yPos];\n },\n render: function render() {\n var _this$props2 = this.props,\n height = _this$props2.height,\n width = _this$props2.width,\n margin = _this$props2.margin,\n colorScale = _this$props2.colorScale,\n values = _this$props2.values,\n label = _this$props2.label,\n y = _this$props2.y,\n y0 = _this$props2.y0,\n x = _this$props2.x;\n var data = this._data;\n var innerWidth = this._innerWidth;\n var xScale = this._xScale;\n var yScale = this._yScale;\n var preserveAspectRatio = 'none';\n var viewBox = \"0 0 \".concat(width, \" \").concat(height); // there are two options, if the samples are less than the space available\n // we'll stretch the width of bar and inbetween spaces.\n // Otherwise we just subSample the dataArray.\n\n var barWidth;\n\n if (data[0].values.length > innerWidth / 2) {\n data[0].values = subSample(data[0].values, innerWidth / 2);\n barWidth = 1;\n } else {\n barWidth = innerWidth / 2 / data[0].values.length;\n }\n\n return _react.default.createElement(\"div\", null, _react.default.createElement(_Chart.default, {\n height: height,\n width: width,\n margin: margin,\n viewBox: viewBox,\n preserveAspectRatio: preserveAspectRatio\n }, _react.default.createElement(DataSet, {\n data: data,\n xScale: xScale,\n yScale: yScale,\n colorScale: colorScale,\n label: label,\n values: values,\n x: x,\n y: y,\n y0: y0,\n x0: barWidth,\n onMouseEnter: this.onMouseEnter,\n onMouseLeave: this.onMouseLeave\n }, this.props.children)));\n }\n});\nvar _default = Waveform;\nexports.default = _default;\n\n//# sourceURL=webpack://ReactD3/./src/Waveform.jsx?");
/***/ }),
/***/ "./src/index.jsx":
/*!***********************!*\
!*** ./src/index.jsx ***!
\***********************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
eval("\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nObject.defineProperty(exports, \"BarChart\", {\n enumerable: true,\n get: function get() {\n return _BarChart.default;\n }\n});\nObject.defineProperty(exports, \"Waveform\", {\n enumerable: true,\n get: function get() {\n return _Waveform.default;\n }\n});\nObject.defineProperty(exports, \"PieChart\", {\n enumerable: true,\n get: function get() {\n return _PieChart.default;\n }\n});\nObject.defineProperty(exports, \"ScatterPlot\", {\n enumerable: true,\n get: function get() {\n return _ScatterPlot.default;\n }\n});\nObject.defineProperty(exports, \"LineChart\", {\n enumerable: true,\n get: function get() {\n return _LineChart.default;\n }\n});\nObject.defineProperty(exports, \"AreaChart\", {\n enumerable: true,\n get: function get() {\n return _AreaChart.default;\n }\n});\nObject.defineProperty(exports, \"Brush\", {\n enumerable: true,\n get: function get() {\n return _Brush.default;\n }\n});\nObject.defineProperty(exports, \"d3\", {\n enumerable: true,\n get: function get() {\n return _d2.default;\n }\n});\n\nvar _BarChart = _interopRequireDefault(__webpack_require__(/*! ./BarChart */ \"./src/BarChart.jsx\"));\n\nvar _Waveform = _interopRequireDefault(__webpack_require__(/*! ./Waveform */ \"./src/Waveform.jsx\"));\n\nvar _PieChart = _interopRequireDefault(__webpack_require__(/*! ./PieChart */ \"./src/PieChart.jsx\"));\n\nvar _ScatterPlot = _interopRequireDefault(__webpack_require__(/*! ./ScatterPlot */ \"./src/ScatterPlot.jsx\"));\n\nvar _LineChart = _interopRequireDefault(__webpack_require__(/*! ./LineChart */ \"./src/LineChart.jsx\"));\n\nvar _AreaChart = _interopRequireDefault(__webpack_require__(/*! ./AreaChart */ \"./src/AreaChart.jsx\"));\n\nvar _Brush = _interopRequireDefault(__webpack_require__(/*! ./Brush */ \"./src/Brush.jsx\"));\n\nvar _d2 = _interopRequireDefault(__webpack_require__(/*! d3 */ \"d3\"));\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n//# sourceURL=webpack://ReactD3/./src/index.jsx?");
/***/ }),
/***/ "d3":
/*!*********************!*\
!*** external "d3" ***!
\*********************/
/*! no static exports found */
/***/ (function(module, exports) {
eval("module.exports = __WEBPACK_EXTERNAL_MODULE_d3__;\n\n//# sourceURL=webpack://ReactD3/external_%22d3%22?");
/***/ }),
/***/ "react":
/*!************************!*\
!*** external "React" ***!
\************************/
/*! no static exports found */
/***/ (function(module, exports) {
eval("module.exports = __WEBPACK_EXTERNAL_MODULE_react__;\n\n//# sourceURL=webpack://ReactD3/external_%22React%22?");
/***/ }),
/***/ "react-dom":
/*!***************************!*\
!*** external "ReactDOM" ***!
\***************************/
/*! no static exports found */
/***/ (function(module, exports) {
eval("module.exports = __WEBPACK_EXTERNAL_MODULE_react_dom__;\n\n//# sourceURL=webpack://ReactD3/external_%22ReactDOM%22?");
/***/ })
/******/ });
});