UNPKG

290 kBJavaScriptView Raw
1(function webpackUniversalModuleDefinition(root, factory) {
2 if(typeof exports === 'object' && typeof module === 'object')
3 module.exports = factory(require("react"), require("react-dom"));
4 else if(typeof define === 'function' && define.amd)
5 define(["react", "react-dom"], factory);
6 else if(typeof exports === 'object')
7 exports["rc-banner-anim"] = factory(require("react"), require("react-dom"));
8 else
9 root["rc-banner-anim"] = factory(root["React"], root["ReactDOM"]);
10})(typeof self !== 'undefined' ? self : this, function(__WEBPACK_EXTERNAL_MODULE_1__, __WEBPACK_EXTERNAL_MODULE_28__) {
11return /******/ (function(modules) { // webpackBootstrap
12/******/ // The module cache
13/******/ var installedModules = {};
14/******/
15/******/ // The require function
16/******/ function __webpack_require__(moduleId) {
17/******/
18/******/ // Check if module is in cache
19/******/ if(installedModules[moduleId]) {
20/******/ return installedModules[moduleId].exports;
21/******/ }
22/******/ // Create a new module (and put it into the cache)
23/******/ var module = installedModules[moduleId] = {
24/******/ i: moduleId,
25/******/ l: false,
26/******/ exports: {}
27/******/ };
28/******/
29/******/ // Execute the module function
30/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
31/******/
32/******/ // Flag the module as loaded
33/******/ module.l = true;
34/******/
35/******/ // Return the exports of the module
36/******/ return module.exports;
37/******/ }
38/******/
39/******/
40/******/ // expose the modules object (__webpack_modules__)
41/******/ __webpack_require__.m = modules;
42/******/
43/******/ // expose the module cache
44/******/ __webpack_require__.c = installedModules;
45/******/
46/******/ // define getter function for harmony exports
47/******/ __webpack_require__.d = function(exports, name, getter) {
48/******/ if(!__webpack_require__.o(exports, name)) {
49/******/ Object.defineProperty(exports, name, {
50/******/ configurable: false,
51/******/ enumerable: true,
52/******/ get: getter
53/******/ });
54/******/ }
55/******/ };
56/******/
57/******/ // getDefaultExport function for compatibility with non-harmony modules
58/******/ __webpack_require__.n = function(module) {
59/******/ var getter = module && module.__esModule ?
60/******/ function getDefault() { return module['default']; } :
61/******/ function getModuleExports() { return module; };
62/******/ __webpack_require__.d(getter, 'a', getter);
63/******/ return getter;
64/******/ };
65/******/
66/******/ // Object.prototype.hasOwnProperty.call
67/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
68/******/
69/******/ // __webpack_public_path__
70/******/ __webpack_require__.p = "";
71/******/
72/******/ // Load entry module and return exports
73/******/ return __webpack_require__(__webpack_require__.s = 67);
74/******/ })
75/************************************************************************/
76/******/ ([
77/* 0 */
78/***/ (function(module, exports, __webpack_require__) {
79
80"use strict";
81
82
83exports.__esModule = true;
84
85var _assign = __webpack_require__(71);
86
87var _assign2 = _interopRequireDefault(_assign);
88
89function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
90
91exports.default = _assign2.default || function (target) {
92 for (var i = 1; i < arguments.length; i++) {
93 var source = arguments[i];
94
95 for (var key in source) {
96 if (Object.prototype.hasOwnProperty.call(source, key)) {
97 target[key] = source[key];
98 }
99 }
100 }
101
102 return target;
103};
104
105/***/ }),
106/* 1 */
107/***/ (function(module, exports) {
108
109module.exports = __WEBPACK_EXTERNAL_MODULE_1__;
110
111/***/ }),
112/* 2 */
113/***/ (function(module, exports) {
114
115// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
116var global = module.exports = typeof window != 'undefined' && window.Math == Math
117 ? window : typeof self != 'undefined' && self.Math == Math ? self
118 // eslint-disable-next-line no-new-func
119 : Function('return this')();
120if (typeof __g == 'number') __g = global; // eslint-disable-line no-undef
121
122
123/***/ }),
124/* 3 */
125/***/ (function(module, exports) {
126
127var core = module.exports = { version: '2.6.9' };
128if (typeof __e == 'number') __e = core; // eslint-disable-line no-undef
129
130
131/***/ }),
132/* 4 */
133/***/ (function(module, exports, __webpack_require__) {
134
135// Thank's IE8 for his funny defineProperty
136module.exports = !__webpack_require__(20)(function () {
137 return Object.defineProperty({}, 'a', { get: function () { return 7; } }).a != 7;
138});
139
140
141/***/ }),
142/* 5 */
143/***/ (function(module, exports, __webpack_require__) {
144
145/* WEBPACK VAR INJECTION */(function(process) {/**
146 * Copyright (c) 2013-present, Facebook, Inc.
147 *
148 * This source code is licensed under the MIT license found in the
149 * LICENSE file in the root directory of this source tree.
150 */
151
152if (process.env.NODE_ENV !== 'production') {
153 var ReactIs = __webpack_require__(59);
154
155 // By explicitly using `prop-types` you are opting into new development behavior.
156 // http://fb.me/prop-types-in-prod
157 var throwOnDirectAccess = true;
158 module.exports = __webpack_require__(113)(ReactIs.isElement, throwOnDirectAccess);
159} else {
160 // By explicitly using `prop-types` you are opting into new production behavior.
161 // http://fb.me/prop-types-in-prod
162 module.exports = __webpack_require__(116)();
163}
164
165/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17)))
166
167/***/ }),
168/* 6 */
169/***/ (function(module, exports, __webpack_require__) {
170
171var anObject = __webpack_require__(19);
172var IE8_DOM_DEFINE = __webpack_require__(49);
173var toPrimitive = __webpack_require__(31);
174var dP = Object.defineProperty;
175
176exports.f = __webpack_require__(4) ? Object.defineProperty : function defineProperty(O, P, Attributes) {
177 anObject(O);
178 P = toPrimitive(P, true);
179 anObject(Attributes);
180 if (IE8_DOM_DEFINE) try {
181 return dP(O, P, Attributes);
182 } catch (e) { /* empty */ }
183 if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported!');
184 if ('value' in Attributes) O[P] = Attributes.value;
185 return O;
186};
187
188
189/***/ }),
190/* 7 */
191/***/ (function(module, exports) {
192
193var hasOwnProperty = {}.hasOwnProperty;
194module.exports = function (it, key) {
195 return hasOwnProperty.call(it, key);
196};
197
198
199/***/ }),
200/* 8 */
201/***/ (function(module, exports, __webpack_require__) {
202
203"use strict";
204
205
206exports.__esModule = true;
207
208exports.default = function (instance, Constructor) {
209 if (!(instance instanceof Constructor)) {
210 throw new TypeError("Cannot call a class as a function");
211 }
212};
213
214/***/ }),
215/* 9 */
216/***/ (function(module, exports, __webpack_require__) {
217
218"use strict";
219
220
221exports.__esModule = true;
222
223var _typeof2 = __webpack_require__(54);
224
225var _typeof3 = _interopRequireDefault(_typeof2);
226
227function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
228
229exports.default = function (self, call) {
230 if (!self) {
231 throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
232 }
233
234 return call && ((typeof call === "undefined" ? "undefined" : (0, _typeof3.default)(call)) === "object" || typeof call === "function") ? call : self;
235};
236
237/***/ }),
238/* 10 */
239/***/ (function(module, exports, __webpack_require__) {
240
241"use strict";
242
243
244exports.__esModule = true;
245
246var _defineProperty = __webpack_require__(101);
247
248var _defineProperty2 = _interopRequireDefault(_defineProperty);
249
250function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
251
252exports.default = function () {
253 function defineProperties(target, props) {
254 for (var i = 0; i < props.length; i++) {
255 var descriptor = props[i];
256 descriptor.enumerable = descriptor.enumerable || false;
257 descriptor.configurable = true;
258 if ("value" in descriptor) descriptor.writable = true;
259 (0, _defineProperty2.default)(target, descriptor.key, descriptor);
260 }
261 }
262
263 return function (Constructor, protoProps, staticProps) {
264 if (protoProps) defineProperties(Constructor.prototype, protoProps);
265 if (staticProps) defineProperties(Constructor, staticProps);
266 return Constructor;
267 };
268}();
269
270/***/ }),
271/* 11 */
272/***/ (function(module, exports, __webpack_require__) {
273
274"use strict";
275
276
277exports.__esModule = true;
278
279var _setPrototypeOf = __webpack_require__(104);
280
281var _setPrototypeOf2 = _interopRequireDefault(_setPrototypeOf);
282
283var _create = __webpack_require__(108);
284
285var _create2 = _interopRequireDefault(_create);
286
287var _typeof2 = __webpack_require__(54);
288
289var _typeof3 = _interopRequireDefault(_typeof2);
290
291function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
292
293exports.default = function (subClass, superClass) {
294 if (typeof superClass !== "function" && superClass !== null) {
295 throw new TypeError("Super expression must either be null or a function, not " + (typeof superClass === "undefined" ? "undefined" : (0, _typeof3.default)(superClass)));
296 }
297
298 subClass.prototype = (0, _create2.default)(superClass && superClass.prototype, {
299 constructor: {
300 value: subClass,
301 enumerable: false,
302 writable: true,
303 configurable: true
304 }
305 });
306 if (superClass) _setPrototypeOf2.default ? (0, _setPrototypeOf2.default)(subClass, superClass) : subClass.__proto__ = superClass;
307};
308
309/***/ }),
310/* 12 */
311/***/ (function(module, exports, __webpack_require__) {
312
313var global = __webpack_require__(2);
314var core = __webpack_require__(3);
315var ctx = __webpack_require__(48);
316var hide = __webpack_require__(13);
317var has = __webpack_require__(7);
318var PROTOTYPE = 'prototype';
319
320var $export = function (type, name, source) {
321 var IS_FORCED = type & $export.F;
322 var IS_GLOBAL = type & $export.G;
323 var IS_STATIC = type & $export.S;
324 var IS_PROTO = type & $export.P;
325 var IS_BIND = type & $export.B;
326 var IS_WRAP = type & $export.W;
327 var exports = IS_GLOBAL ? core : core[name] || (core[name] = {});
328 var expProto = exports[PROTOTYPE];
329 var target = IS_GLOBAL ? global : IS_STATIC ? global[name] : (global[name] || {})[PROTOTYPE];
330 var key, own, out;
331 if (IS_GLOBAL) source = name;
332 for (key in source) {
333 // contains in native
334 own = !IS_FORCED && target && target[key] !== undefined;
335 if (own && has(exports, key)) continue;
336 // export native or passed
337 out = own ? target[key] : source[key];
338 // prevent global pollution for namespaces
339 exports[key] = IS_GLOBAL && typeof target[key] != 'function' ? source[key]
340 // bind timers to global for call from export context
341 : IS_BIND && own ? ctx(out, global)
342 // wrap global constructors for prevent change them in library
343 : IS_WRAP && target[key] == out ? (function (C) {
344 var F = function (a, b, c) {
345 if (this instanceof C) {
346 switch (arguments.length) {
347 case 0: return new C();
348 case 1: return new C(a);
349 case 2: return new C(a, b);
350 } return new C(a, b, c);
351 } return C.apply(this, arguments);
352 };
353 F[PROTOTYPE] = C[PROTOTYPE];
354 return F;
355 // make static versions for prototype methods
356 })(out) : IS_PROTO && typeof out == 'function' ? ctx(Function.call, out) : out;
357 // export proto methods to core.%CONSTRUCTOR%.methods.%NAME%
358 if (IS_PROTO) {
359 (exports.virtual || (exports.virtual = {}))[key] = out;
360 // export proto methods to core.%CONSTRUCTOR%.prototype.%NAME%
361 if (type & $export.R && expProto && !expProto[key]) hide(expProto, key, out);
362 }
363 }
364};
365// type bitmap
366$export.F = 1; // forced
367$export.G = 2; // global
368$export.S = 4; // static
369$export.P = 8; // proto
370$export.B = 16; // bind
371$export.W = 32; // wrap
372$export.U = 64; // safe
373$export.R = 128; // real proto method for `library`
374module.exports = $export;
375
376
377/***/ }),
378/* 13 */
379/***/ (function(module, exports, __webpack_require__) {
380
381var dP = __webpack_require__(6);
382var createDesc = __webpack_require__(23);
383module.exports = __webpack_require__(4) ? function (object, key, value) {
384 return dP.f(object, key, createDesc(1, value));
385} : function (object, key, value) {
386 object[key] = value;
387 return object;
388};
389
390
391/***/ }),
392/* 14 */
393/***/ (function(module, exports) {
394
395module.exports = function (it) {
396 return typeof it === 'object' ? it !== null : typeof it === 'function';
397};
398
399
400/***/ }),
401/* 15 */
402/***/ (function(module, exports, __webpack_require__) {
403
404// to indexed object, toObject with fallback for non-array-like ES3 strings
405var IObject = __webpack_require__(52);
406var defined = __webpack_require__(32);
407module.exports = function (it) {
408 return IObject(defined(it));
409};
410
411
412/***/ }),
413/* 16 */
414/***/ (function(module, exports, __webpack_require__) {
415
416var store = __webpack_require__(35)('wks');
417var uid = __webpack_require__(26);
418var Symbol = __webpack_require__(2).Symbol;
419var USE_SYMBOL = typeof Symbol == 'function';
420
421var $exports = module.exports = function (name) {
422 return store[name] || (store[name] =
423 USE_SYMBOL && Symbol[name] || (USE_SYMBOL ? Symbol : uid)('Symbol.' + name));
424};
425
426$exports.store = store;
427
428
429/***/ }),
430/* 17 */
431/***/ (function(module, exports) {
432
433// shim for using process in browser
434var process = module.exports = {};
435
436// cached from whatever global is present so that test runners that stub it
437// don't break things. But we need to wrap it in a try catch in case it is
438// wrapped in strict mode code which doesn't define any globals. It's inside a
439// function because try/catches deoptimize in certain engines.
440
441var cachedSetTimeout;
442var cachedClearTimeout;
443
444function defaultSetTimout() {
445 throw new Error('setTimeout has not been defined');
446}
447function defaultClearTimeout () {
448 throw new Error('clearTimeout has not been defined');
449}
450(function () {
451 try {
452 if (typeof setTimeout === 'function') {
453 cachedSetTimeout = setTimeout;
454 } else {
455 cachedSetTimeout = defaultSetTimout;
456 }
457 } catch (e) {
458 cachedSetTimeout = defaultSetTimout;
459 }
460 try {
461 if (typeof clearTimeout === 'function') {
462 cachedClearTimeout = clearTimeout;
463 } else {
464 cachedClearTimeout = defaultClearTimeout;
465 }
466 } catch (e) {
467 cachedClearTimeout = defaultClearTimeout;
468 }
469} ())
470function runTimeout(fun) {
471 if (cachedSetTimeout === setTimeout) {
472 //normal enviroments in sane situations
473 return setTimeout(fun, 0);
474 }
475 // if setTimeout wasn't available but was latter defined
476 if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {
477 cachedSetTimeout = setTimeout;
478 return setTimeout(fun, 0);
479 }
480 try {
481 // when when somebody has screwed with setTimeout but no I.E. maddness
482 return cachedSetTimeout(fun, 0);
483 } catch(e){
484 try {
485 // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
486 return cachedSetTimeout.call(null, fun, 0);
487 } catch(e){
488 // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error
489 return cachedSetTimeout.call(this, fun, 0);
490 }
491 }
492
493
494}
495function runClearTimeout(marker) {
496 if (cachedClearTimeout === clearTimeout) {
497 //normal enviroments in sane situations
498 return clearTimeout(marker);
499 }
500 // if clearTimeout wasn't available but was latter defined
501 if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
502 cachedClearTimeout = clearTimeout;
503 return clearTimeout(marker);
504 }
505 try {
506 // when when somebody has screwed with setTimeout but no I.E. maddness
507 return cachedClearTimeout(marker);
508 } catch (e){
509 try {
510 // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
511 return cachedClearTimeout.call(null, marker);
512 } catch (e){
513 // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.
514 // Some versions of I.E. have different rules for clearTimeout vs setTimeout
515 return cachedClearTimeout.call(this, marker);
516 }
517 }
518
519
520
521}
522var queue = [];
523var draining = false;
524var currentQueue;
525var queueIndex = -1;
526
527function cleanUpNextTick() {
528 if (!draining || !currentQueue) {
529 return;
530 }
531 draining = false;
532 if (currentQueue.length) {
533 queue = currentQueue.concat(queue);
534 } else {
535 queueIndex = -1;
536 }
537 if (queue.length) {
538 drainQueue();
539 }
540}
541
542function drainQueue() {
543 if (draining) {
544 return;
545 }
546 var timeout = runTimeout(cleanUpNextTick);
547 draining = true;
548
549 var len = queue.length;
550 while(len) {
551 currentQueue = queue;
552 queue = [];
553 while (++queueIndex < len) {
554 if (currentQueue) {
555 currentQueue[queueIndex].run();
556 }
557 }
558 queueIndex = -1;
559 len = queue.length;
560 }
561 currentQueue = null;
562 draining = false;
563 runClearTimeout(timeout);
564}
565
566process.nextTick = function (fun) {
567 var args = new Array(arguments.length - 1);
568 if (arguments.length > 1) {
569 for (var i = 1; i < arguments.length; i++) {
570 args[i - 1] = arguments[i];
571 }
572 }
573 queue.push(new Item(fun, args));
574 if (queue.length === 1 && !draining) {
575 runTimeout(drainQueue);
576 }
577};
578
579// v8 likes predictible objects
580function Item(fun, array) {
581 this.fun = fun;
582 this.array = array;
583}
584Item.prototype.run = function () {
585 this.fun.apply(null, this.array);
586};
587process.title = 'browser';
588process.browser = true;
589process.env = {};
590process.argv = [];
591process.version = ''; // empty string to avoid regexp issues
592process.versions = {};
593
594function noop() {}
595
596process.on = noop;
597process.addListener = noop;
598process.once = noop;
599process.off = noop;
600process.removeListener = noop;
601process.removeAllListeners = noop;
602process.emit = noop;
603process.prependListener = noop;
604process.prependOnceListener = noop;
605
606process.listeners = function (name) { return [] }
607
608process.binding = function (name) {
609 throw new Error('process.binding is not supported');
610};
611
612process.cwd = function () { return '/' };
613process.chdir = function (dir) {
614 throw new Error('process.chdir is not supported');
615};
616process.umask = function() { return 0; };
617
618
619/***/ }),
620/* 18 */
621/***/ (function(module, __webpack_exports__, __webpack_require__) {
622
623"use strict";
624/* harmony export (immutable) */ __webpack_exports__["f"] = toArrayChildren;
625/* harmony export (immutable) */ __webpack_exports__["c"] = dataToArray;
626/* harmony export (immutable) */ __webpack_exports__["d"] = setAnimCompToTagComp;
627/* harmony export (immutable) */ __webpack_exports__["b"] = currentScrollTop;
628/* harmony export (immutable) */ __webpack_exports__["a"] = currentScrollLeft;
629/* harmony export (immutable) */ __webpack_exports__["g"] = windowHeight;
630/* harmony export (immutable) */ __webpack_exports__["e"] = switchChildren;
631/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(1);
632/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__);
633/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types__ = __webpack_require__(5);
634/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_prop_types__);
635
636
637
638function toArrayChildren(children) {
639 var ret = [];
640 __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.forEach(children, function (c) {
641 ret.push(c);
642 });
643 return ret;
644}
645
646function dataToArray(vars) {
647 if (!vars && vars !== 0) {
648 return [];
649 }
650 if (Array.isArray(vars)) {
651 return vars;
652 }
653 return [vars];
654}
655
656function setAnimCompToTagComp(item, i) {
657 if (!item) {
658 return null;
659 }
660 var itemProps = item.props;
661 if (!itemProps.component) {
662 return item;
663 }
664 var props = {};
665 props.key = item.key || i;
666 // dom global attributes
667 var domAttrArray = ['accesskey', 'classname', 'contenteditable', 'contextmenu', 'dir', 'draggable', 'dropzone', 'hidden', 'id', 'lang', 'spellcheck', 'style', 'tabindex', 'title'];
668 Object.keys(itemProps).forEach(function (key) {
669 if (domAttrArray.indexOf(key.toLocaleLowerCase()) >= 0 || key.match('data-')) {
670 props[key] = itemProps[key];
671 }
672 });
673 return __WEBPACK_IMPORTED_MODULE_0_react___default.a.createElement(itemProps.component, props, itemProps.children);
674}
675setAnimCompToTagComp.propTypes = {
676 key: __WEBPACK_IMPORTED_MODULE_1_prop_types___default.a.string
677};
678
679function currentScrollTop() {
680 return window.pageYOffset || document.body.scrollTop || document.documentElement.scrollTop;
681}
682
683function currentScrollLeft() {
684 return window.pageXOffset || document.body.scrollLeft || document.documentElement.scrollLeft;
685}
686
687function windowHeight() {
688 return window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight;
689}
690
691function switchChildren(hideProps, item) {
692 if (!hideProps) {
693 return item;
694 }
695 if (item.type.isTweenOne) {
696 return __WEBPACK_IMPORTED_MODULE_0_react___default.a.cloneElement(item, { reverse: true });
697 }
698 return __WEBPACK_IMPORTED_MODULE_0_react___default.a.cloneElement(item, item.props, null);
699}
700
701/***/ }),
702/* 19 */
703/***/ (function(module, exports, __webpack_require__) {
704
705var isObject = __webpack_require__(14);
706module.exports = function (it) {
707 if (!isObject(it)) throw TypeError(it + ' is not an object!');
708 return it;
709};
710
711
712/***/ }),
713/* 20 */
714/***/ (function(module, exports) {
715
716module.exports = function (exec) {
717 try {
718 return !!exec();
719 } catch (e) {
720 return true;
721 }
722};
723
724
725/***/ }),
726/* 21 */
727/***/ (function(module, __webpack_exports__, __webpack_require__) {
728
729"use strict";
730/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "m", function() { return windowIsUndefined; });
731/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "l", function() { return transformOrFilter; });
732/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "i", function() { return styleValueToArray; });
733/* harmony export (immutable) */ __webpack_exports__["j"] = toArrayChildren;
734/* harmony export (immutable) */ __webpack_exports__["a"] = dataToArray;
735/* harmony export (immutable) */ __webpack_exports__["f"] = objectEqual;
736/* harmony export (immutable) */ __webpack_exports__["b"] = findChildInChildrenByKey;
737/* harmony export (immutable) */ __webpack_exports__["e"] = mergeChildren;
738/* harmony export (immutable) */ __webpack_exports__["k"] = transformArguments;
739/* harmony export (immutable) */ __webpack_exports__["c"] = getChildrenFromProps;
740/* harmony export (immutable) */ __webpack_exports__["h"] = startConvertToEndUnit;
741/* harmony export (immutable) */ __webpack_exports__["g"] = parsePath;
742/* harmony export (immutable) */ __webpack_exports__["d"] = getTransformValue;
743/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react__ = __webpack_require__(1);
744/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_react__);
745
746
747var windowIsUndefined = !(typeof window !== 'undefined' && window.document && window.document.createElement);
748
749var transformOrFilter = {
750 transform: 1,
751 '-ms-transform': 1,
752 '-moz-transform': 1,
753 '-webkit-transform': 1,
754 '-o-transform': 1,
755 filter: 1,
756 '-webkit-filter': 1
757};
758
759var styleValueToArray = {
760 margin: 1,
761 padding: 1,
762 borderWidth: 1,
763 borderRadius: 1
764};
765
766function toArrayChildren(children) {
767 var ret = [];
768 __WEBPACK_IMPORTED_MODULE_0_react___default.a.Children.forEach(children, function (c) {
769 ret.push(c);
770 });
771 return ret;
772}
773
774function dataToArray(vars) {
775 if (!vars && vars !== 0) {
776 return [];
777 }
778 if (Array.isArray(vars)) {
779 return vars;
780 }
781 return [vars];
782}
783
784function deepEql(a, b) {
785 if (!a || !b) {
786 return false;
787 }
788 var $a = Object.keys(a);
789 var $b = Object.keys(b);
790 if ($a.length && $b.length && $a.length === $b.length) {
791 return !$a.some(function (key) {
792 var aa = a[key];
793 var bb = b[key];
794 if (Array.isArray(aa) && Array.isArray(bb)) {
795 aa = aa.join();
796 bb = bb.join();
797 }
798 return aa !== bb;
799 });
800 }
801 return false;
802}
803
804function objectEqual(obj1, obj2) {
805 if (obj1 === obj2 || deepEql(obj1, obj2)) {
806 return true;
807 }
808 if (!obj1 || !obj2) {
809 return false;
810 }
811 // animation 写在标签上的进行判断是否相等, 判断每个参数有没有 function;
812 var equalBool = true;
813 if (Array.isArray(obj1) && Array.isArray(obj2)) {
814 if (obj1.length !== obj2.length) {
815 return false;
816 }
817 for (var i = 0; i < obj1.length; i++) {
818 var currentObj = obj1[i];
819 var nextObj = obj2[i];
820 for (var p in currentObj) {
821 // eslint-disable-line no-restricted-syntax
822 if (currentObj[p] !== nextObj[p]) {
823 if (typeof currentObj[p] === 'object' && typeof nextObj[p] === 'object') {
824 equalBool = objectEqual(currentObj[p], nextObj[p]);
825 } else if (typeof currentObj[p] === 'function' && typeof nextObj[p] === 'function') {
826 if (currentObj[p].name !== nextObj[p].name) {
827 equalBool = false;
828 }
829 } else {
830 equalBool = false;
831 }
832 if (!equalBool) {
833 return false;
834 }
835 }
836 }
837 }
838 }
839
840 var setEqualBool = function setEqualBool(objA, objB) {
841 Object.keys(objA).forEach(function (key) {
842 // 如果前面有参数匹配不相同则直接返回;
843 if (!equalBool) {
844 return;
845 }
846 if (!(key in objB)) {
847 equalBool = false;
848 }
849
850 if (typeof objA[key] === 'object' && typeof objB[key] === 'object') {
851 equalBool = objectEqual(objA[key], objB[key]);
852 } else if (typeof objA[key] === 'function' && typeof objB[key] === 'function') {
853 if (objA[key].name !== objB[key].name) {
854 equalBool = false;
855 }
856 } else if (objA[key] !== objB[key]) {
857 equalBool = false;
858 }
859 });
860 };
861
862 setEqualBool(obj1, obj2);
863 setEqualBool(obj2, obj1);
864 return equalBool;
865}
866
867function findChildInChildrenByKey(children, key) {
868 var ret = null;
869 if (children) {
870 children.forEach(function (c) {
871 if (ret || !c) {
872 return;
873 }
874 if (c.key === key) {
875 ret = c;
876 }
877 });
878 }
879 return ret;
880}
881
882function mergeChildren(prev, next) {
883 var ret = [];
884 // For each key of `next`, the list of keys to insert before that key in
885 // the combined list
886 var nextChildrenPending = {};
887 var pendingChildren = [];
888 var followChildrenKey = void 0;
889 prev.forEach(function (c) {
890 if (!c) {
891 return;
892 }
893 if (findChildInChildrenByKey(next, c.key)) {
894 if (pendingChildren.length) {
895 nextChildrenPending[c.key] = pendingChildren;
896 pendingChildren = [];
897 }
898 followChildrenKey = c.key;
899 } else if (c.key) {
900 pendingChildren.push(c);
901 }
902 });
903 if (!followChildrenKey) {
904 ret = ret.concat(pendingChildren);
905 }
906
907 next.forEach(function (c) {
908 if (!c) {
909 return;
910 }
911 if (nextChildrenPending.hasOwnProperty(c.key)) {
912 // eslint-disable-line no-prototype-builtins
913 ret = ret.concat(nextChildrenPending[c.key]);
914 }
915 ret.push(c);
916 if (c.key === followChildrenKey) {
917 ret = ret.concat(pendingChildren);
918 }
919 });
920
921 return ret;
922}
923
924function transformArguments(arg, key, i) {
925 var result = void 0;
926 if (typeof arg === 'function') {
927 result = arg({
928 key: key,
929 index: i
930 });
931 } else {
932 result = arg;
933 }
934 return result;
935}
936
937function getChildrenFromProps(props) {
938 return props && props.children;
939}
940
941function startConvertToEndUnit(target, computedStyle, style, num, unit, dataUnit, fixed, isOriginWidth) {
942 if (windowIsUndefined) {
943 return num;
944 }
945 var horiz = /(?:Left|Right|Width|X)/i.test(style) || isOriginWidth;
946 horiz = style === 'padding' || style === 'marign' ? true : horiz;
947 var t = style.indexOf('border') !== -1 || style.indexOf('translate') !== -1 || style === 'transformOrigin' ? target : target.parentNode || document.body;
948 t = fixed ? document.body : t;
949 var pix = void 0;
950 var htmlComputedStyle = void 0;
951 // transform 在 safari 下会留着单位,chrome 下会全部转换成 px;
952 switch (unit) {
953 case '%':
954 pix = parseFloat(num) / 100 * (horiz ? t.clientWidth : t.clientHeight);
955 break;
956 case 'vw':
957 pix = parseFloat(num) * document.body.clientWidth / 100;
958 break;
959 case 'vh':
960 pix = parseFloat(num) * document.body.clientHeight / 100;
961 break;
962 case 'em':
963 pix = parseFloat(num) * parseFloat(computedStyle.fontSize);
964 break;
965 case 'rem':
966 {
967 htmlComputedStyle = window.getComputedStyle(document.getElementsByTagName('html')[0]);
968 pix = parseFloat(num) * parseFloat(htmlComputedStyle.fontSize);
969 break;
970 }
971 default:
972 pix = parseFloat(num);
973 break;
974 }
975 switch (dataUnit) {
976 case '%':
977 pix = pix ? pix * 100 / (horiz ? t.clientWidth : t.clientHeight) : 0;
978 break;
979 case 'vw':
980 pix = parseFloat(num) / document.body.clientWidth * 100;
981 break;
982 case 'vh':
983 pix = parseFloat(num) / document.body.clientHeight * 100;
984 break;
985 case 'em':
986 pix = parseFloat(num) / parseFloat(computedStyle.fontSize);
987 break;
988 case 'rem':
989 {
990 htmlComputedStyle = htmlComputedStyle || window.getComputedStyle(document.getElementsByTagName('html')[0]);
991 pix = parseFloat(num) / parseFloat(htmlComputedStyle.fontSize);
992 break;
993 }
994 default:
995 break;
996 }
997 return pix;
998}
999
1000function parsePath(path) {
1001 if (typeof path === 'string') {
1002 if (path.charAt(0).match(/m/i)) {
1003 var domPath = document.createElementNS('http://www.w3.org/2000/svg', 'path');
1004 domPath.setAttributeNS(null, 'd', path);
1005 return domPath;
1006 }
1007 return document.querySelector(path);
1008 } else if (path.style) {
1009 return path;
1010 }
1011 throw new Error('Error while parsing the path');
1012}
1013
1014function getTransformValue(t) {
1015 if (typeof t === 'string') {
1016 return t;
1017 }
1018 var perspective = t.perspective;
1019 var angle = t.rotate;
1020 var rotateX = t.rotateX;
1021 var rotateY = t.rotateY;
1022 var sx = t.scaleX;
1023 var sy = t.scaleY;
1024 var sz = t.scaleZ;
1025 var skx = t.skewX;
1026 var sky = t.skewY;
1027 var translateX = typeof t.translateX === 'string' ? t.translateX : t.translateX + 'px';
1028 var translateY = typeof t.translateY === 'string' ? t.translateY : t.translateY + 'px';
1029 var translateZ = typeof t.translateZ === 'string' ? t.translateZ : t.translateZ + 'px';
1030 var sk = skx || sky ? 'skew(' + skx + 'deg,' + sky + 'deg)' : '';
1031 var an = angle ? 'rotate(' + angle + 'deg)' : '';
1032 var ss = sx !== 1 || sy !== 1 || sz !== 1 ? 'scale3d(' + sx + ',' + sy + ',' + sz + ')' : '';
1033 var rX = rotateX ? 'rotateX(' + rotateX + 'deg)' : '';
1034 var rY = rotateY ? 'rotateY(' + rotateY + 'deg)' : '';
1035 var per = perspective ? 'perspective(' + perspective + 'px)' : '';
1036 var defaultTranslate = ss || an || rX || rY || sk ? '' : 'translate(0px, 0px)';
1037 var translate = t.translateZ ? 'translate3d(' + translateX + ',' + translateY + ',' + translateZ + ')' : (t.translateX || t.translateY) && 'translate(' + translateX + ',' + translateY + ')' || defaultTranslate;
1038 return (per + ' ' + translate + ' ' + ss + ' ' + an + ' ' + rX + ' ' + rY + ' ' + sk).trim();
1039}
1040
1041/***/ }),
1042/* 22 */
1043/***/ (function(module, __webpack_exports__, __webpack_require__) {
1044
1045"use strict";
1046/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return polyfill; });
1047/**
1048 * Copyright (c) 2013-present, Facebook, Inc.
1049 *
1050 * This source code is licensed under the MIT license found in the
1051 * LICENSE file in the root directory of this source tree.
1052 */
1053
1054function componentWillMount() {
1055 // Call this.constructor.gDSFP to support sub-classes.
1056 var state = this.constructor.getDerivedStateFromProps(this.props, this.state);
1057 if (state !== null && state !== undefined) {
1058 this.setState(state);
1059 }
1060}
1061
1062function componentWillReceiveProps(nextProps) {
1063 // Call this.constructor.gDSFP to support sub-classes.
1064 // Use the setState() updater to ensure state isn't stale in certain edge cases.
1065 function updater(prevState) {
1066 var state = this.constructor.getDerivedStateFromProps(nextProps, prevState);
1067 return state !== null && state !== undefined ? state : null;
1068 }
1069 // Binding "this" is important for shallow renderer support.
1070 this.setState(updater.bind(this));
1071}
1072
1073function componentWillUpdate(nextProps, nextState) {
1074 try {
1075 var prevProps = this.props;
1076 var prevState = this.state;
1077 this.props = nextProps;
1078 this.state = nextState;
1079 this.__reactInternalSnapshotFlag = true;
1080 this.__reactInternalSnapshot = this.getSnapshotBeforeUpdate(
1081 prevProps,
1082 prevState
1083 );
1084 } finally {
1085 this.props = prevProps;
1086 this.state = prevState;
1087 }
1088}
1089
1090// React may warn about cWM/cWRP/cWU methods being deprecated.
1091// Add a flag to suppress these warnings for this special case.
1092componentWillMount.__suppressDeprecationWarning = true;
1093componentWillReceiveProps.__suppressDeprecationWarning = true;
1094componentWillUpdate.__suppressDeprecationWarning = true;
1095
1096function polyfill(Component) {
1097 var prototype = Component.prototype;
1098
1099 if (!prototype || !prototype.isReactComponent) {
1100 throw new Error('Can only polyfill class components');
1101 }
1102
1103 if (
1104 typeof Component.getDerivedStateFromProps !== 'function' &&
1105 typeof prototype.getSnapshotBeforeUpdate !== 'function'
1106 ) {
1107 return Component;
1108 }
1109
1110 // If new component APIs are defined, "unsafe" lifecycles won't be called.
1111 // Error if any of these lifecycles are present,
1112 // Because they would work differently between older and newer (16.3+) versions of React.
1113 var foundWillMountName = null;
1114 var foundWillReceivePropsName = null;
1115 var foundWillUpdateName = null;
1116 if (typeof prototype.componentWillMount === 'function') {
1117 foundWillMountName = 'componentWillMount';
1118 } else if (typeof prototype.UNSAFE_componentWillMount === 'function') {
1119 foundWillMountName = 'UNSAFE_componentWillMount';
1120 }
1121 if (typeof prototype.componentWillReceiveProps === 'function') {
1122 foundWillReceivePropsName = 'componentWillReceiveProps';
1123 } else if (typeof prototype.UNSAFE_componentWillReceiveProps === 'function') {
1124 foundWillReceivePropsName = 'UNSAFE_componentWillReceiveProps';
1125 }
1126 if (typeof prototype.componentWillUpdate === 'function') {
1127 foundWillUpdateName = 'componentWillUpdate';
1128 } else if (typeof prototype.UNSAFE_componentWillUpdate === 'function') {
1129 foundWillUpdateName = 'UNSAFE_componentWillUpdate';
1130 }
1131 if (
1132 foundWillMountName !== null ||
1133 foundWillReceivePropsName !== null ||
1134 foundWillUpdateName !== null
1135 ) {
1136 var componentName = Component.displayName || Component.name;
1137 var newApiName =
1138 typeof Component.getDerivedStateFromProps === 'function'
1139 ? 'getDerivedStateFromProps()'
1140 : 'getSnapshotBeforeUpdate()';
1141
1142 throw Error(
1143 'Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n' +
1144 componentName +
1145 ' uses ' +
1146 newApiName +
1147 ' but also contains the following legacy lifecycles:' +
1148 (foundWillMountName !== null ? '\n ' + foundWillMountName : '') +
1149 (foundWillReceivePropsName !== null
1150 ? '\n ' + foundWillReceivePropsName
1151 : '') +
1152 (foundWillUpdateName !== null ? '\n ' + foundWillUpdateName : '') +
1153 '\n\nThe above lifecycles should be removed. Learn more about this warning here:\n' +
1154 'https://fb.me/react-async-component-lifecycle-hooks'
1155 );
1156 }
1157
1158 // React <= 16.2 does not support static getDerivedStateFromProps.
1159 // As a workaround, use cWM and cWRP to invoke the new static lifecycle.
1160 // Newer versions of React will ignore these lifecycles if gDSFP exists.
1161 if (typeof Component.getDerivedStateFromProps === 'function') {
1162 prototype.componentWillMount = componentWillMount;
1163 prototype.componentWillReceiveProps = componentWillReceiveProps;
1164 }
1165
1166 // React <= 16.2 does not support getSnapshotBeforeUpdate.
1167 // As a workaround, use cWU to invoke the new lifecycle.
1168 // Newer versions of React will ignore that lifecycle if gSBU exists.
1169 if (typeof prototype.getSnapshotBeforeUpdate === 'function') {
1170 if (typeof prototype.componentDidUpdate !== 'function') {
1171 throw new Error(
1172 'Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype'
1173 );
1174 }
1175
1176 prototype.componentWillUpdate = componentWillUpdate;
1177
1178 var componentDidUpdate = prototype.componentDidUpdate;
1179
1180 prototype.componentDidUpdate = function componentDidUpdatePolyfill(
1181 prevProps,
1182 prevState,
1183 maybeSnapshot
1184 ) {
1185 // 16.3+ will not execute our will-update method;
1186 // It will pass a snapshot value to did-update though.
1187 // Older versions will require our polyfilled will-update value.
1188 // We need to handle both cases, but can't just check for the presence of "maybeSnapshot",
1189 // Because for <= 15.x versions this might be a "prevContext" object.
1190 // We also can't just check "__reactInternalSnapshot",
1191 // Because get-snapshot might return a falsy value.
1192 // So check for the explicit __reactInternalSnapshotFlag flag to determine behavior.
1193 var snapshot = this.__reactInternalSnapshotFlag
1194 ? this.__reactInternalSnapshot
1195 : maybeSnapshot;
1196
1197 componentDidUpdate.call(this, prevProps, prevState, snapshot);
1198 };
1199 }
1200
1201 return Component;
1202}
1203
1204
1205
1206
1207/***/ }),
1208/* 23 */
1209/***/ (function(module, exports) {
1210
1211module.exports = function (bitmap, value) {
1212 return {
1213 enumerable: !(bitmap & 1),
1214 configurable: !(bitmap & 2),
1215 writable: !(bitmap & 4),
1216 value: value
1217 };
1218};
1219
1220
1221/***/ }),
1222/* 24 */
1223/***/ (function(module, exports, __webpack_require__) {
1224
1225// 19.1.2.14 / 15.2.3.14 Object.keys(O)
1226var $keys = __webpack_require__(51);
1227var enumBugKeys = __webpack_require__(36);
1228
1229module.exports = Object.keys || function keys(O) {
1230 return $keys(O, enumBugKeys);
1231};
1232
1233
1234/***/ }),
1235/* 25 */
1236/***/ (function(module, exports) {
1237
1238module.exports = true;
1239
1240
1241/***/ }),
1242/* 26 */
1243/***/ (function(module, exports) {
1244
1245var id = 0;
1246var px = Math.random();
1247module.exports = function (key) {
1248 return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36));
1249};
1250
1251
1252/***/ }),
1253/* 27 */
1254/***/ (function(module, exports) {
1255
1256exports.f = {}.propertyIsEnumerable;
1257
1258
1259/***/ }),
1260/* 28 */
1261/***/ (function(module, exports) {
1262
1263module.exports = __WEBPACK_EXTERNAL_MODULE_28__;
1264
1265/***/ }),
1266/* 29 */
1267/***/ (function(module, exports, __webpack_require__) {
1268
1269"use strict";
1270
1271
1272Object.defineProperty(exports, "__esModule", {
1273 value: true
1274});
1275exports.toCssLowerCase = toCssLowerCase;
1276exports.toStyleUpperCase = toStyleUpperCase;
1277exports.toFixed = toFixed;
1278exports.createMatrix = createMatrix;
1279exports.checkStyleName = checkStyleName;
1280exports.getGsapType = getGsapType;
1281exports.parseColor = parseColor;
1282exports.parseShadow = parseShadow;
1283exports.getColor = getColor;
1284exports.isTransform = isTransform;
1285exports.isConvert = isConvert;
1286exports.splitFilterToObject = splitFilterToObject;
1287exports.getMatrix = getMatrix;
1288exports.getTransform = getTransform;
1289exports.stylesToCss = stylesToCss;
1290exports.getUnit = getUnit;
1291exports.getValues = getValues;
1292exports.findStyleByName = findStyleByName;
1293exports.mergeStyle = mergeStyle;
1294var isUnitlessNumber = {
1295 animationIterationCount: true,
1296 borderImageOutset: true,
1297 borderImageSlice: true,
1298 borderImageWidth: true,
1299 boxFlex: true,
1300 boxFlexGroup: true,
1301 boxOrdinalGroup: true,
1302 columnCount: true,
1303 flex: true,
1304 flexGrow: true,
1305 flexPositive: true,
1306 flexShrink: true,
1307 flexNegative: true,
1308 flexOrder: true,
1309 gridRow: true,
1310 gridColumn: true,
1311 fontWeight: true,
1312 lineClamp: true,
1313 lineHeight: true,
1314 opacity: true,
1315 order: true,
1316 orphans: true,
1317 tabSize: true,
1318 widows: true,
1319 zIndex: true,
1320 zoom: true,
1321
1322 // SVG-related properties
1323 fillOpacity: true,
1324 floodOpacity: true,
1325 stopOpacity: true,
1326 strokeDasharray: true,
1327 strokeDashoffset: true,
1328 strokeMiterlimit: true,
1329 strokeOpacity: true,
1330 strokeWidth: true
1331};
1332var prefixes = ['Webkit', 'ms', 'Moz', 'O'];
1333
1334function prefixKey(prefix, key) {
1335 return prefix + key.charAt(0).toUpperCase() + key.substring(1);
1336}
1337
1338Object.keys(isUnitlessNumber).forEach(function (prop) {
1339 prefixes.forEach(function (prefix) {
1340 isUnitlessNumber[prefixKey(prefix, prop)] = isUnitlessNumber[prop];
1341 });
1342});
1343
1344var unquotedContentValueRegex = /^(normal|none|(\b(url\([^)]*\)|chapter_counter|attr\([^)]*\)|(no-)?(open|close)-quote|inherit)((\b\s*)|$|\s+))+)$/;
1345
1346var IE = function () {
1347 if (typeof document === 'undefined') {
1348 return false;
1349 }
1350 if (navigator && (navigator.userAgent.indexOf("MSIE 8.0") > 0 || navigator.userAgent.indexOf("MSIE 9.0") > 0)) {
1351 return true;
1352 }
1353 return false;
1354}();
1355
1356var rnd = 100000;
1357
1358var colorLookup = {
1359 aqua: [0, 255, 255],
1360 lime: [0, 255, 0],
1361 silver: [192, 192, 192],
1362 black: [0, 0, 0],
1363 maroon: [128, 0, 0],
1364 teal: [0, 128, 128],
1365 blue: [0, 0, 255],
1366 navy: [0, 0, 128],
1367 white: [255, 255, 255],
1368 fuchsia: [255, 0, 255],
1369 olive: [128, 128, 0],
1370 yellow: [255, 255, 0],
1371 orange: [255, 165, 0],
1372 gray: [128, 128, 128],
1373 purple: [128, 0, 128],
1374 green: [0, 128, 0],
1375 red: [255, 0, 0],
1376 pink: [255, 192, 203],
1377 cyan: [0, 255, 255],
1378 transparent: [255, 255, 255, 0]
1379};
1380var _hue = function _hue(hh, m1, m2) {
1381 var h = hh > 1 ? hh - 1 : hh;
1382 h = hh < 0 ? hh + 1 : h;
1383 var a = h * 3 < 2 ? m1 + (m2 - m1) * (2 / 3 - h) * 6 : m1;
1384 var b = h < 0.5 ? m2 : a;
1385 var c = h * 6 < 1 ? m1 + (m2 - m1) * h * 6 : b;
1386 return c * 255 + 0.5 | 0;
1387};
1388var DEG2RAD = Math.PI / 180;
1389var RAD2DEG = 180 / Math.PI;
1390
1391var $cssList = {
1392 _lists: {
1393 transformsBase: ['translate', 'translateX', 'translateY', 'scale', 'scaleX', 'scaleY', 'skewX', 'skewY', 'rotateZ', 'rotate'],
1394 transforms3D: ['translate3d', 'translateZ', 'scaleZ', 'rotateX', 'rotateY', 'perspective']
1395 },
1396 transformGroup: { translate: 1, translate3d: 1, scale: 1, scale3d: 1, rotate: 1, rotate3d: 1, skew: 1 },
1397 filter: ['grayScale', 'sepia', 'hueRotate', 'invert', 'brightness', 'contrast', 'blur'],
1398 filterConvert: { grayScale: 'grayscale', hueRotate: 'hue-rotate' }
1399};
1400$cssList._lists.transformsBase = !IE ? $cssList._lists.transformsBase.concat($cssList._lists.transforms3D) : $cssList._lists.transformsBase;
1401
1402var cssList = exports.cssList = $cssList;
1403
1404function toCssLowerCase(d) {
1405 return d.replace(/[A-Z]/, function ($1) {
1406 return '-' + $1.toLocaleLowerCase();
1407 });
1408}
1409
1410function toStyleUpperCase(d) {
1411 return d.replace(/-(.?)/g, function ($1) {
1412 return $1.replace('-', '').toLocaleUpperCase();
1413 });
1414}
1415
1416function toFixed(num, length) {
1417 var _rnd = length ? Math.pow(10, length) : rnd;
1418 var n = num | 0;
1419 var dec = num - n;
1420 var fixed = num;
1421 if (dec) {
1422 var r = (dec * _rnd + (num < 0 ? -0.5 : 0.5) | 0) / _rnd;
1423 var t = r | 0;
1424 var str = r.toString();
1425 var decStr = str.split('.')[1] || '';
1426 fixed = '' + (num < 0 && !(n + t) ? '-' : '') + (n + t) + '.' + decStr;
1427 }
1428 return parseFloat(fixed);
1429}
1430
1431function createMatrix(style) {
1432 if (typeof document === 'undefined') {
1433 return null;
1434 }
1435 var matrixs = ['WebKitCSS', 'MozCSS', 'DOM', 'MsCSS', 'MSCSS', 'OCSS', 'CSS'].filter(function (key) {
1436 return key + 'Matrix' in window;
1437 });
1438 if (matrixs.length) {
1439 return new window[matrixs[0] + 'Matrix'](style);
1440 }
1441 console.warn('Browsers do not support matrix.');
1442 return '';
1443}
1444
1445function checkStyleName(p) {
1446 if (typeof document === 'undefined') {
1447 return null;
1448 }
1449 var a = ['O', 'Moz', 'ms', 'Ms', 'Webkit'];
1450 if (p !== 'filter' && p in document.body.style) {
1451 return p;
1452 }
1453 var _p = p.charAt(0).toUpperCase() + p.substr(1);
1454 var prefixCss = a.filter(function (key) {
1455 return '' + key + _p in document.body.style;
1456 });
1457 return prefixCss[0] ? '' + prefixCss[0] + _p : null;
1458}
1459
1460function getGsapType(_p) {
1461 var p = _p;
1462 p = p === 'x' ? 'translateX' : p;
1463 p = p === 'y' ? 'translateY' : p;
1464 p = p === 'z' ? 'translateZ' : p;
1465 // p = p === 'r' ? 'rotate' : p;
1466 return p;
1467}
1468
1469function parseColor(_v) {
1470 var a = void 0;
1471 var r = void 0;
1472 var g = void 0;
1473 var b = void 0;
1474 var h = void 0;
1475 var s = void 0;
1476 var l = void 0;
1477 var v = _v;
1478 var _numExp = /(?:\d|\-\d|\.\d|\-\.\d)+/g;
1479 if (!v) {
1480 a = colorLookup.black;
1481 } else if (typeof v === 'number') {
1482 a = [v >> 16, v >> 8 & 255, v & 255];
1483 } else {
1484 if (v.charAt(v.length - 1) === ',') {
1485 v = v.substr(0, v.length - 1);
1486 }
1487 if (colorLookup[v]) {
1488 a = colorLookup[v];
1489 } else if (v.charAt(0) === '#') {
1490 // is #FFF
1491 if (v.length === 4) {
1492 r = v.charAt(1);
1493 g = v.charAt(2);
1494 b = v.charAt(3);
1495 v = '#' + r + r + g + g + b + b;
1496 }
1497 v = parseInt(v.substr(1), 16);
1498 a = [v >> 16, v >> 8 & 255, v & 255];
1499 } else if (v.substr(0, 3) === 'hsl') {
1500 a = v.match(_numExp);
1501 h = Number(a[0]) % 360 / 360;
1502 s = Number(a[1]) / 100;
1503 l = Number(a[2]) / 100;
1504 g = l <= 0.5 ? l * (s + 1) : l + s - l * s;
1505 r = l * 2 - g;
1506 if (a.length > 3) {
1507 a[3] = Number(a[3]);
1508 }
1509 a[0] = _hue(h + 1 / 3, r, g);
1510 a[1] = _hue(h, r, g);
1511 a[2] = _hue(h - 1 / 3, r, g);
1512 } else {
1513 a = v.match(_numExp) || colorLookup.transparent;
1514 }
1515 a[0] = Number(a[0]);
1516 a[1] = Number(a[1]);
1517 a[2] = Number(a[2]);
1518
1519 if (a.length > 3) {
1520 a[3] = Number(a[3]);
1521 }
1522 }
1523 return a;
1524}
1525
1526function parseShadow(v) {
1527 if (!v) {
1528 return [0, 0, 0, 0, 0, 0, 0];
1529 }
1530 var inset = void 0;
1531 if (v.indexOf('rgb') >= 0) {
1532 var t = v.match(/rgb+(?:a)?\((.*)\)/);
1533 var s = v.replace(t[0], '').trim().split(/\s+/);
1534 inset = s.indexOf('inset');
1535 if (inset >= 0) {
1536 s.splice(inset, 1);
1537 }
1538 var c = t[1].replace(/\s+/g, '').split(',');
1539 if (c.length === 3) {
1540 c.push(1);
1541 }
1542 return s.concat(c, inset >= 0 ? ['inset'] : []);
1543 }
1544 var vArr = v.split(/\s+/);
1545 inset = vArr.indexOf('inset');
1546 if (inset >= 0) {
1547 vArr.splice(inset, 1);
1548 }
1549 var color = parseColor(vArr[vArr.length - 1]);
1550 color[3] = typeof color[3] === 'number' ? color[3] : 1;
1551 vArr = vArr.splice(0, vArr.length - 1);
1552 return vArr.concat(color, inset >= 0 ? ['inset'] : []);
1553}
1554
1555function getColor(v) {
1556 var rgba = v.length === 4 ? 'rgba' : 'rgb';
1557 var _vars = v.map(function (d, i) {
1558 return i < 3 ? Math.round(d) : d;
1559 });
1560 return rgba + '(' + _vars.join(',') + ')';
1561}
1562
1563function isTransform(p) {
1564 return cssList._lists.transformsBase.indexOf(p) >= 0 ? 'transform' : p;
1565}
1566
1567function isConvert(p) {
1568 var cssName = isTransform(p);
1569 return cssList.filter.indexOf(cssName) >= 0 ? 'filter' : cssName;
1570}
1571
1572function splitFilterToObject(data) {
1573 if (data === 'none' || !data || data === '') {
1574 return null;
1575 }
1576 var filter = data.replace(' ', '').split(')').filter(function (item) {
1577 return item;
1578 });
1579 var startData = {};
1580 filter.forEach(function (item) {
1581 var dataArr = item.split('(');
1582 startData[dataArr[0]] = dataArr[1];
1583 });
1584 return startData;
1585}
1586
1587function getMatrix(t) {
1588 var arr = t.match(/(?:\-|\b)[\d\-\.e]+\b/gi);
1589 var m = {};
1590 if (arr.length === 6) {
1591 m.m11 = parseFloat(arr[0]);
1592 m.m12 = parseFloat(arr[1]);
1593 m.m13 = 0;
1594 m.m14 = 0;
1595 m.m21 = parseFloat(arr[2]);
1596 m.m22 = parseFloat(arr[3]);
1597 m.m23 = 0;
1598 m.m24 = 0;
1599 m.m31 = 0;
1600 m.m32 = 0;
1601 m.m33 = 1;
1602 m.m34 = 0;
1603 m.m41 = parseFloat(arr[4]);
1604 m.m42 = parseFloat(arr[5]);
1605 m.m43 = 0;
1606 m.m44 = 0;
1607 } else {
1608 arr.forEach(function (item, i) {
1609 var ii = i % 4 + 1;
1610 var j = Math.floor(i / 4) + 1;
1611 m['m' + j + ii] = parseFloat(item);
1612 });
1613 }
1614 return m;
1615}
1616
1617function transformNoMatrix(transform) {
1618 var tm = {};
1619 tm.translateX = 0;
1620 tm.translateY = 0;
1621 tm.translateZ = 0;
1622 tm.rotate = 0;
1623 tm.rotateX = 0;
1624 tm.rotateY = 0;
1625 tm.scaleX = 1;
1626 tm.scaleY = 1;
1627 tm.scaleZ = 1;
1628 tm.skewX = 0;
1629 tm.skewY = 0;
1630 tm.perspective = 0;
1631 (transform.trim().match(/(\w+)\([^\)]+\)/ig) || []).forEach(function (str) {
1632 var strArray = str.split('(');
1633 var key = strArray[0].trim();
1634 var value = strArray[1].replace(')', '').trim();
1635 if (value.match(/%|em|rem/ig)) {
1636 console.warn('value(' + value + ') must be absolute, not relative, has been converted to absolute.');
1637 }
1638 value = value.replace(/px|deg|\)/ig, '');
1639 if (cssList.transformGroup[key] && key !== 'rotate') {
1640 value = value.split(',').map(function (num) {
1641 return parseFloat(num);
1642 });
1643 if (key === 'scale3d' || key === 'translate3d') {
1644 ['X', 'Y', 'Z'].forEach(function (s, i) {
1645 var $key = key.substring(0, key.length - 2);
1646 tm['' + $key + s] = value[i] || tm['' + $key + s];
1647 });
1648 } else if (key === 'rotate3d') {
1649 tm.rotateX = value[0] && value[3] || tm.rotateX;
1650 tm.rotateY = value[1] && value[3] || tm.rotateY;
1651 tm.rotate = value[2] && value[3] || tm.rotate;
1652 } else {
1653 ['X', 'Y'].forEach(function (s, i) {
1654 tm['' + key + s] = value[i] || tm['' + key + s];
1655 });
1656 }
1657 } else {
1658 if (key === 'rotateZ') {
1659 tm.rotate = parseFloat(value) || tm.rotate;
1660 } else {
1661 tm[key] = parseFloat(value) || tm[key];
1662 }
1663 }
1664 });
1665 return tm;
1666}
1667
1668function getTransform(transform) {
1669 var _transform = !transform || transform === 'none' || transform === '' ? 'matrix(1, 0, 0, 1, 0, 0)' : transform;
1670 if (!_transform.match('matrix')) {
1671 return transformNoMatrix(transform);
1672 }
1673 var m = getMatrix(_transform);
1674 var m11 = m.m11;
1675 var m12 = m.m12;
1676 var m13 = m.m13;
1677 var m14 = m.m14;
1678 var m21 = m.m21;
1679 var m22 = m.m22;
1680 var m23 = m.m23;
1681 var m24 = m.m24;
1682 var m31 = m.m31;
1683 var m32 = m.m32;
1684 var m33 = m.m33;
1685 var m34 = m.m34;
1686 var m43 = m.m43;
1687 var t1 = void 0;
1688 var t2 = void 0;
1689 var t3 = void 0;
1690 var tm = {};
1691 var angle = Math.atan2(m23, m33);
1692 var skewX = Math.tan(m21);
1693 var skewY = Math.tan(m12);
1694 var cos = void 0;
1695 var sin = void 0;
1696 // rotateX
1697 tm.rotateX = toFixed(angle * RAD2DEG) || 0;
1698 if (angle) {
1699 cos = Math.cos(-angle);
1700 sin = Math.sin(-angle);
1701 t1 = m21 * cos + m31 * sin;
1702 t2 = m22 * cos + m32 * sin;
1703 t3 = m23 * cos + m33 * sin;
1704 m31 = m21 * -sin + m31 * cos;
1705 m32 = m22 * -sin + m32 * cos;
1706 m33 = m23 * -sin + m33 * cos;
1707 m34 = m24 * -sin + m34 * cos;
1708 m21 = t1;
1709 m22 = t2;
1710 m23 = t3;
1711 }
1712 // rotateY
1713 angle = Math.atan2(-m13, m33);
1714 tm.rotateY = toFixed(angle * RAD2DEG) || 0;
1715 if (angle) {
1716 cos = Math.cos(-angle);
1717 sin = Math.sin(-angle);
1718 t1 = m11 * cos - m31 * sin;
1719 t2 = m12 * cos - m32 * sin;
1720 t3 = m13 * cos - m33 * sin;
1721 m32 = m12 * sin + m32 * cos;
1722 m33 = m13 * sin + m33 * cos;
1723 m34 = m14 * sin + m34 * cos;
1724 m11 = t1;
1725 m12 = t2;
1726 m13 = t3;
1727 }
1728 // rotateZ
1729 angle = Math.atan2(m12, m11);
1730 tm.rotate = toFixed(angle * RAD2DEG) || 0;
1731 if (angle) {
1732 cos = Math.cos(angle);
1733 sin = Math.sin(angle);
1734 t1 = m11 * cos + m12 * sin;
1735 t2 = m21 * cos + m22 * sin;
1736 t3 = m31 * cos + m32 * sin;
1737 m12 = m12 * cos - m11 * sin;
1738 m22 = m22 * cos - m21 * sin;
1739 m32 = m32 * cos - m31 * sin;
1740 m11 = t1;
1741 m21 = t2;
1742 m31 = t3;
1743 }
1744
1745 if (tm.rotateX && Math.abs(tm.rotateX) + Math.abs(tm.rotate) > 359.9) {
1746 tm.rotateX = tm.rotate = 0;
1747 tm.rotateY = 180 - tm.rotateY || 0;
1748 }
1749
1750 tm.scaleX = toFixed(Math.sqrt(m11 * m11 + m12 * m12 + m13 * m13));
1751 tm.scaleY = toFixed(Math.sqrt(m22 * m22 + m23 * m23));
1752 tm.scaleZ = toFixed(Math.sqrt(m31 * m31 + m32 * m32 + m33 * m33));
1753 // 不管 skewX skewY了;
1754 tm.skewX = skewX === -skewY ? 0 : skewX;
1755 tm.skewY = skewY === -skewX ? 0 : skewY;
1756 tm.perspective = m34 ? 1 / (m34 < 0 ? -m34 : m34) : 0;
1757 tm.translateX = m.m41;
1758 tm.translateY = m.m42;
1759 tm.translateZ = m43;
1760 return tm;
1761}
1762
1763function stylesToCss(key, value) {
1764 var _value = void 0;
1765 if (!isUnitlessNumber[key] && typeof value === 'number') {
1766 _value = ' ' + value + 'px';
1767 } else if (key === 'content' && !unquotedContentValueRegex.test(value)) {
1768 _value = '\'' + value.replace(/'/g, "\\'") + '\'';
1769 }
1770 return _value || value;
1771}
1772
1773function getUnit(p, v) {
1774 var currentUnit = v && v.toString().replace(/[^a-z|%]/ig, '');
1775 var unit = '';
1776 if (p.indexOf('translate') >= 0 || p.indexOf('perspective') >= 0 || p.indexOf('blur') >= 0) {
1777 unit = 'px';
1778 } else if (p.indexOf('skew') >= 0 || p.indexOf('rotate') >= 0) {
1779 unit = 'deg';
1780 }
1781 return currentUnit || unit;
1782}
1783
1784function getValues(p, d, u) {
1785 return p + '(' + d + (u || '') + ')';
1786}
1787
1788function findStyleByName(cssArray, name) {
1789 var ret = null;
1790 if (cssArray) {
1791 cssArray.forEach(function (_cname) {
1792 if (ret) {
1793 return;
1794 }
1795 var cName = _cname.split('(')[0];
1796 var a = cName in cssList.transformGroup && name.substring(0, name.length - 1).indexOf(cName) >= 0;
1797 var b = name in cssList.transformGroup && cName.substring(0, cName.length - 1).indexOf(name) >= 0;
1798 var c = cName in cssList.transformGroup && name in cssList.transformGroup && (cName.substring(0, cName.length - 2) === name || name.substring(0, name.length - 2) === cName);
1799 if (cName === name || a || b || c) {
1800 ret = _cname;
1801 }
1802 });
1803 }
1804 return ret;
1805}
1806
1807function mergeStyle(current, change) {
1808 if (!current || current === '') {
1809 return change;
1810 }
1811 if (!change || change === '') {
1812 return current;
1813 }
1814 var _current = current.replace(/\s/g, '').split(')').filter(function (item) {
1815 return item !== '' && item;
1816 }).map(function (item) {
1817 return item + ')';
1818 });
1819 var _change = change.replace(/\s/g, '').split(')').filter(function (item) {
1820 return item !== '' && item;
1821 });
1822 _change.forEach(function (changeOnly) {
1823 var changeArr = changeOnly.split('(');
1824 var changeName = changeArr[0];
1825 var currentSame = findStyleByName(_current, changeName);
1826 if (!currentSame) {
1827 _current.push(changeOnly + ')');
1828 } else {
1829 var index = _current.indexOf(currentSame);
1830 _current[index] = changeOnly + ')';
1831 }
1832 });
1833 _current.forEach(function (item, i) {
1834 if (item.indexOf('perspective') >= 0 && i) {
1835 _current.splice(i, 1);
1836 _current.unshift(item);
1837 }
1838 });
1839 return _current.join(' ').trim();
1840}
1841
1842
1843/***/ }),
1844/* 30 */
1845/***/ (function(module, __webpack_exports__, __webpack_require__) {
1846
1847"use strict";
1848/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__ = __webpack_require__(0);
1849/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__);
1850/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_react__ = __webpack_require__(1);
1851/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_react__);
1852/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__utils__ = __webpack_require__(18);
1853
1854
1855
1856
1857/* harmony default export */ __webpack_exports__["a"] = ({
1858 across: function across(elem, type, direction, animData, elemOffset, leaveChildHide) {
1859 var _x = void 0;
1860 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, elem.props);
1861 var children = props.children;
1862 if (type === 'enter') {
1863 _x = direction === 'next' ? '100%' : '-100%';
1864 } else {
1865 // 时间轴不同,导致中间有空隙, 等修复 twee-one,先加delay
1866 _x = direction === 'next' ? '-100%' : '100%';
1867 children = Object(__WEBPACK_IMPORTED_MODULE_2__utils__["f" /* toArrayChildren */])(children).map(__WEBPACK_IMPORTED_MODULE_2__utils__["e" /* switchChildren */].bind(this, leaveChildHide));
1868 }
1869 return Object(__WEBPACK_IMPORTED_MODULE_1_react__["cloneElement"])(elem, {
1870 animation: __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, animData, {
1871 x: _x,
1872 type: type === 'enter' ? 'from' : 'to'
1873 })
1874 }, children);
1875 },
1876 vertical: function vertical(elem, type, direction, animData, elemOffset, leaveChildHide) {
1877 var _y = void 0;
1878 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, elem.props);
1879 var children = props.children;
1880 if (type === 'enter') {
1881 _y = direction === 'next' ? '-100%' : '100%';
1882 } else {
1883 // 时间轴不同,导致中间有空隙, 等修复 twee-one,先加delay
1884 _y = direction === 'next' ? '100%' : '-100%';
1885 children = Object(__WEBPACK_IMPORTED_MODULE_2__utils__["f" /* toArrayChildren */])(children).map(__WEBPACK_IMPORTED_MODULE_2__utils__["e" /* switchChildren */].bind(this, leaveChildHide));
1886 }
1887 return Object(__WEBPACK_IMPORTED_MODULE_1_react__["cloneElement"])(elem, __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, props, {
1888 animation: __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, animData, {
1889 y: _y,
1890 type: type === 'enter' ? 'from' : 'to'
1891 })
1892 }), children);
1893 },
1894 acrossOverlay: function acrossOverlay(elem, type, direction, animData, elemOffset, leaveChildHide) {
1895 var _x = void 0;
1896 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, elem.props);
1897 var children = props.children;
1898 if (type === 'enter') {
1899 _x = direction === 'next' ? '100%' : '-100%';
1900 } else {
1901 _x = direction === 'next' ? '-20%' : '20%';
1902 children = Object(__WEBPACK_IMPORTED_MODULE_2__utils__["f" /* toArrayChildren */])(children).map(__WEBPACK_IMPORTED_MODULE_2__utils__["e" /* switchChildren */].bind(this, leaveChildHide));
1903 }
1904 return Object(__WEBPACK_IMPORTED_MODULE_1_react__["cloneElement"])(elem, __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, props, {
1905 animation: __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, animData, {
1906 x: _x,
1907 type: type === 'enter' ? 'from' : 'to'
1908 })
1909 }), children);
1910 },
1911 verticalOverlay: function verticalOverlay(elem, type, direction, animData, elemOffset, leaveChildHide) {
1912 var _y = void 0;
1913 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, elem.props);
1914 var children = props.children;
1915 if (type === 'enter') {
1916 _y = direction === 'next' ? '-100%' : '100%';
1917 } else {
1918 _y = direction === 'next' ? '20%' : '-20%';
1919 children = Object(__WEBPACK_IMPORTED_MODULE_2__utils__["f" /* toArrayChildren */])(children).map(__WEBPACK_IMPORTED_MODULE_2__utils__["e" /* switchChildren */].bind(this, leaveChildHide));
1920 }
1921 return Object(__WEBPACK_IMPORTED_MODULE_1_react__["cloneElement"])(elem, __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, props, {
1922 animation: __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, animData, {
1923 y: _y,
1924 type: type === 'enter' ? 'from' : 'to'
1925 })
1926 }), children);
1927 },
1928 gridBar: function gridBar(elem, type, direction, animData, elemOffset, leaveChildHide, ratio, paused) {
1929 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, elem.props);
1930 var animChild = [];
1931 var gridNum = 10;
1932 var girdSize = 100 / gridNum;
1933
1934 var _y = void 0;
1935 var children = props.children;
1936 if (type === 'enter') {
1937 _y = direction === 'next' ? '-100%' : '100%';
1938 } else {
1939 _y = direction === 'next' ? '100%' : '-100%';
1940 }
1941 var moment = ratio * (animData.duration + animData.delay + gridNum * 50 - (type === 'enter' ? 50 : 0)) || 0;
1942 for (var i = 0; i < gridNum; i++) {
1943 var style = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, props.style);
1944 style.width = girdSize + 0.1 + '%';
1945 style.left = i * girdSize + '%';
1946 style.position = 'absolute';
1947 style.overflow = 'hidden';
1948 var _style = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, props.style);
1949 _style.width = elemOffset.width + 'px';
1950 _style.height = elemOffset.height + 'px';
1951 _style.float = 'left';
1952 _style.position = 'relative';
1953 _style.left = -i * girdSize / 100 * elemOffset.width + 'px';
1954 _style.overflow = 'hidden';
1955 var animProps = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, props);
1956 animProps.style = _style;
1957 var delay = (direction === 'next' ? i : gridNum - i) * 50 + (type === 'enter' ? 0 : 50) + (animData.delay || 0);
1958 animProps.animation = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, animData, {
1959 y: _y,
1960 type: type === 'enter' ? 'from' : 'to',
1961 key: type,
1962 direction: direction,
1963 delay: delay,
1964 i: i,
1965 onComplete: i === (direction === 'next' ? gridNum - 1 : 0) ? animData.onComplete : null
1966 });
1967 animProps.paused = paused;
1968 animProps.moment = moment;
1969 var mask = __WEBPACK_IMPORTED_MODULE_1_react___default.a.createElement(
1970 'div',
1971 { style: style, key: i },
1972 Object(__WEBPACK_IMPORTED_MODULE_1_react__["cloneElement"])(elem, animProps, children)
1973 );
1974 animChild.push(mask);
1975 }
1976 var animSlot = __WEBPACK_IMPORTED_MODULE_1_react___default.a.createElement(
1977 'div',
1978 { style: { width: '100%', position: 'absolute', top: 0 } },
1979 animChild
1980 );
1981 var _props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, elem.props);
1982 _props.children = animSlot;
1983 return Object(__WEBPACK_IMPORTED_MODULE_1_react__["cloneElement"])(elem, __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, _props, { animation: { x: 0, y: 0, type: 'set' } }));
1984 },
1985 grid: function grid(elem, type, direction, animData, elemOffset, leaveChildHide, ratio, paused) {
1986 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, elem.props);
1987 var animChild = [];
1988 var gridNum = 10;
1989 var gridWidth = elemOffset.width / gridNum;
1990 var gridNumH = Math.ceil(elemOffset.height / gridWidth);
1991 var _delay = (gridNum - 1) * 50 + (gridNumH - 1) * 50;
1992 if (type === 'leave') {
1993 props.animation = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, animData, {
1994 duration: _delay + animData.duration
1995 });
1996 props.moment = ((animData.delay || 0) + _delay + animData.duration) * ratio || 0;
1997 props.paused = paused;
1998 return __WEBPACK_IMPORTED_MODULE_1_react___default.a.cloneElement(elem, props);
1999 }
2000 var moment = ratio * (animData.duration + animData.delay + _delay) || 0;
2001 for (var i = 0; i < gridNum * gridNumH; i++) {
2002 // mask样式
2003 var style = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, props.style);
2004 style.position = 'absolute';
2005 style.overflow = 'hidden';
2006 style.width = gridWidth + 1 + 'px';
2007 style.height = gridWidth + 1 + 'px';
2008 style.left = i % gridNum * gridWidth;
2009 style.top = Math.floor(i / gridNum) * gridWidth;
2010 style.opacity = 0;
2011 // clone 的样式
2012 var _style = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, props.style);
2013 _style.width = elemOffset.width + 'px';
2014 _style.height = elemOffset.height + 'px';
2015 _style.position = 'relative';
2016 _style.left = -i % gridNum * gridWidth;
2017 _style.top = -Math.floor(i / gridNum) * gridWidth;
2018 _style.overflow = 'hidden';
2019 props.style = _style;
2020 var delay = direction === 'next' ? i % gridNum * 50 + Math.floor(i / gridNum) * 50 : (gridNum - 1 - i % gridNum) * 50 + (gridNumH - 1 - Math.floor(i / gridNum)) * 50;
2021 delay += animData.delay || 0;
2022 var length = direction === 'next' ? gridNum * gridNumH - 1 : 0;
2023 var animation = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, animData, {
2024 opacity: 1,
2025 delay: delay,
2026 onComplete: i === length ? animData.onComplete : null
2027 });
2028 var mask = __WEBPACK_IMPORTED_MODULE_1_react___default.a.createElement(
2029 elem.type,
2030 {
2031 style: style,
2032 key: i,
2033 paused: paused,
2034 animation: animation,
2035 moment: moment
2036 },
2037 Object(__WEBPACK_IMPORTED_MODULE_1_react__["cloneElement"])(elem, props)
2038 );
2039 animChild.push(mask);
2040 }
2041 var _props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, elem.props);
2042 _props.children = animChild;
2043 return Object(__WEBPACK_IMPORTED_MODULE_1_react__["cloneElement"])(elem, __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, _props, { animation: { x: 0, y: 0, type: 'set' } }));
2044 }
2045});
2046
2047/***/ }),
2048/* 31 */
2049/***/ (function(module, exports, __webpack_require__) {
2050
2051// 7.1.1 ToPrimitive(input [, PreferredType])
2052var isObject = __webpack_require__(14);
2053// instead of the ES6 spec version, we didn't implement @@toPrimitive case
2054// and the second argument - flag - preferred type is a string
2055module.exports = function (it, S) {
2056 if (!isObject(it)) return it;
2057 var fn, val;
2058 if (S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it))) return val;
2059 if (typeof (fn = it.valueOf) == 'function' && !isObject(val = fn.call(it))) return val;
2060 if (!S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it))) return val;
2061 throw TypeError("Can't convert object to primitive value");
2062};
2063
2064
2065/***/ }),
2066/* 32 */
2067/***/ (function(module, exports) {
2068
2069// 7.2.1 RequireObjectCoercible(argument)
2070module.exports = function (it) {
2071 if (it == undefined) throw TypeError("Can't call method on " + it);
2072 return it;
2073};
2074
2075
2076/***/ }),
2077/* 33 */
2078/***/ (function(module, exports) {
2079
2080// 7.1.4 ToInteger
2081var ceil = Math.ceil;
2082var floor = Math.floor;
2083module.exports = function (it) {
2084 return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it);
2085};
2086
2087
2088/***/ }),
2089/* 34 */
2090/***/ (function(module, exports, __webpack_require__) {
2091
2092var shared = __webpack_require__(35)('keys');
2093var uid = __webpack_require__(26);
2094module.exports = function (key) {
2095 return shared[key] || (shared[key] = uid(key));
2096};
2097
2098
2099/***/ }),
2100/* 35 */
2101/***/ (function(module, exports, __webpack_require__) {
2102
2103var core = __webpack_require__(3);
2104var global = __webpack_require__(2);
2105var SHARED = '__core-js_shared__';
2106var store = global[SHARED] || (global[SHARED] = {});
2107
2108(module.exports = function (key, value) {
2109 return store[key] || (store[key] = value !== undefined ? value : {});
2110})('versions', []).push({
2111 version: core.version,
2112 mode: __webpack_require__(25) ? 'pure' : 'global',
2113 copyright: '© 2019 Denis Pushkarev (zloirock.ru)'
2114});
2115
2116
2117/***/ }),
2118/* 36 */
2119/***/ (function(module, exports) {
2120
2121// IE 8- don't enum bug keys
2122module.exports = (
2123 'constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf'
2124).split(',');
2125
2126
2127/***/ }),
2128/* 37 */
2129/***/ (function(module, exports) {
2130
2131exports.f = Object.getOwnPropertySymbols;
2132
2133
2134/***/ }),
2135/* 38 */
2136/***/ (function(module, exports, __webpack_require__) {
2137
2138// 7.1.13 ToObject(argument)
2139var defined = __webpack_require__(32);
2140module.exports = function (it) {
2141 return Object(defined(it));
2142};
2143
2144
2145/***/ }),
2146/* 39 */
2147/***/ (function(module, exports) {
2148
2149module.exports = {};
2150
2151
2152/***/ }),
2153/* 40 */
2154/***/ (function(module, exports, __webpack_require__) {
2155
2156// 19.1.2.2 / 15.2.3.5 Object.create(O [, Properties])
2157var anObject = __webpack_require__(19);
2158var dPs = __webpack_require__(84);
2159var enumBugKeys = __webpack_require__(36);
2160var IE_PROTO = __webpack_require__(34)('IE_PROTO');
2161var Empty = function () { /* empty */ };
2162var PROTOTYPE = 'prototype';
2163
2164// Create object with fake `null` prototype: use iframe Object with cleared prototype
2165var createDict = function () {
2166 // Thrash, waste and sodomy: IE GC bug
2167 var iframe = __webpack_require__(50)('iframe');
2168 var i = enumBugKeys.length;
2169 var lt = '<';
2170 var gt = '>';
2171 var iframeDocument;
2172 iframe.style.display = 'none';
2173 __webpack_require__(85).appendChild(iframe);
2174 iframe.src = 'javascript:'; // eslint-disable-line no-script-url
2175 // createDict = iframe.contentWindow.Object;
2176 // html.removeChild(iframe);
2177 iframeDocument = iframe.contentWindow.document;
2178 iframeDocument.open();
2179 iframeDocument.write(lt + 'script' + gt + 'document.F=Object' + lt + '/script' + gt);
2180 iframeDocument.close();
2181 createDict = iframeDocument.F;
2182 while (i--) delete createDict[PROTOTYPE][enumBugKeys[i]];
2183 return createDict();
2184};
2185
2186module.exports = Object.create || function create(O, Properties) {
2187 var result;
2188 if (O !== null) {
2189 Empty[PROTOTYPE] = anObject(O);
2190 result = new Empty();
2191 Empty[PROTOTYPE] = null;
2192 // add "__proto__" for Object.getPrototypeOf polyfill
2193 result[IE_PROTO] = O;
2194 } else result = createDict();
2195 return Properties === undefined ? result : dPs(result, Properties);
2196};
2197
2198
2199/***/ }),
2200/* 41 */
2201/***/ (function(module, exports, __webpack_require__) {
2202
2203var def = __webpack_require__(6).f;
2204var has = __webpack_require__(7);
2205var TAG = __webpack_require__(16)('toStringTag');
2206
2207module.exports = function (it, tag, stat) {
2208 if (it && !has(it = stat ? it : it.prototype, TAG)) def(it, TAG, { configurable: true, value: tag });
2209};
2210
2211
2212/***/ }),
2213/* 42 */
2214/***/ (function(module, exports, __webpack_require__) {
2215
2216exports.f = __webpack_require__(16);
2217
2218
2219/***/ }),
2220/* 43 */
2221/***/ (function(module, exports, __webpack_require__) {
2222
2223var global = __webpack_require__(2);
2224var core = __webpack_require__(3);
2225var LIBRARY = __webpack_require__(25);
2226var wksExt = __webpack_require__(42);
2227var defineProperty = __webpack_require__(6).f;
2228module.exports = function (name) {
2229 var $Symbol = core.Symbol || (core.Symbol = LIBRARY ? {} : global.Symbol || {});
2230 if (name.charAt(0) != '_' && !(name in $Symbol)) defineProperty($Symbol, name, { value: wksExt.f(name) });
2231};
2232
2233
2234/***/ }),
2235/* 44 */
2236/***/ (function(module, exports, __webpack_require__) {
2237
2238"use strict";
2239/**
2240 * Copyright (c) 2013-present, Facebook, Inc.
2241 *
2242 * This source code is licensed under the MIT license found in the
2243 * LICENSE file in the root directory of this source tree.
2244 */
2245
2246
2247
2248var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';
2249
2250module.exports = ReactPropTypesSecret;
2251
2252
2253/***/ }),
2254/* 45 */
2255/***/ (function(module, __webpack_exports__, __webpack_require__) {
2256
2257"use strict";
2258/* unused harmony export TweenOneGroup */
2259/* unused harmony export easing */
2260/* unused harmony export plugins */
2261/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return ticker; });
2262/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Tween; });
2263/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__TweenOne__ = __webpack_require__(60);
2264/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__Tween__ = __webpack_require__(61);
2265/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__TweenOneGroup__ = __webpack_require__(121);
2266/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__easing__ = __webpack_require__(62);
2267/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__plugins__ = __webpack_require__(46);
2268/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__ticker__ = __webpack_require__(64);
2269// export this package's api
2270
2271
2272
2273
2274
2275
2276
2277__WEBPACK_IMPORTED_MODULE_0__TweenOne__["a" /* default */].TweenOneGroup = __WEBPACK_IMPORTED_MODULE_2__TweenOneGroup__["a" /* default */];
2278__WEBPACK_IMPORTED_MODULE_0__TweenOne__["a" /* default */].easing = __WEBPACK_IMPORTED_MODULE_3__easing__["a" /* default */];
2279__WEBPACK_IMPORTED_MODULE_0__TweenOne__["a" /* default */].plugins = __WEBPACK_IMPORTED_MODULE_4__plugins__["a" /* default */];
2280__WEBPACK_IMPORTED_MODULE_0__TweenOne__["a" /* default */].ticker = __WEBPACK_IMPORTED_MODULE_5__ticker__["a" /* default */];
2281__WEBPACK_IMPORTED_MODULE_0__TweenOne__["a" /* default */].Tween = __WEBPACK_IMPORTED_MODULE_1__Tween__["a" /* default */];
2282
2283/* harmony default export */ __webpack_exports__["b"] = (__WEBPACK_IMPORTED_MODULE_0__TweenOne__["a" /* default */]);
2284
2285var TweenOneGroup = __WEBPACK_IMPORTED_MODULE_2__TweenOneGroup__["a" /* default */];
2286
2287var easing = __WEBPACK_IMPORTED_MODULE_3__easing__["a" /* default */];
2288
2289var plugins = __WEBPACK_IMPORTED_MODULE_4__plugins__["a" /* default */];
2290
2291var ticker = __WEBPACK_IMPORTED_MODULE_5__ticker__["a" /* default */];
2292
2293var Tween = __WEBPACK_IMPORTED_MODULE_1__Tween__["a" /* default */];
2294
2295/***/ }),
2296/* 46 */
2297/***/ (function(module, __webpack_exports__, __webpack_require__) {
2298
2299"use strict";
2300/* eslint-disable func-names */
2301var Plugins = function Plugins() {};
2302var p = Plugins.prototype;
2303p.push = function (plugin) {
2304 this[plugin.prototype.name] = plugin;
2305};
2306/* harmony default export */ __webpack_exports__["a"] = (new Plugins());
2307
2308/***/ }),
2309/* 47 */
2310/***/ (function(module, exports, __webpack_require__) {
2311
2312"use strict";
2313
2314
2315exports.__esModule = true;
2316
2317exports.default = function (obj, keys) {
2318 var target = {};
2319
2320 for (var i in obj) {
2321 if (keys.indexOf(i) >= 0) continue;
2322 if (!Object.prototype.hasOwnProperty.call(obj, i)) continue;
2323 target[i] = obj[i];
2324 }
2325
2326 return target;
2327};
2328
2329/***/ }),
2330/* 48 */
2331/***/ (function(module, exports, __webpack_require__) {
2332
2333// optional / simple context binding
2334var aFunction = __webpack_require__(74);
2335module.exports = function (fn, that, length) {
2336 aFunction(fn);
2337 if (that === undefined) return fn;
2338 switch (length) {
2339 case 1: return function (a) {
2340 return fn.call(that, a);
2341 };
2342 case 2: return function (a, b) {
2343 return fn.call(that, a, b);
2344 };
2345 case 3: return function (a, b, c) {
2346 return fn.call(that, a, b, c);
2347 };
2348 }
2349 return function (/* ...args */) {
2350 return fn.apply(that, arguments);
2351 };
2352};
2353
2354
2355/***/ }),
2356/* 49 */
2357/***/ (function(module, exports, __webpack_require__) {
2358
2359module.exports = !__webpack_require__(4) && !__webpack_require__(20)(function () {
2360 return Object.defineProperty(__webpack_require__(50)('div'), 'a', { get: function () { return 7; } }).a != 7;
2361});
2362
2363
2364/***/ }),
2365/* 50 */
2366/***/ (function(module, exports, __webpack_require__) {
2367
2368var isObject = __webpack_require__(14);
2369var document = __webpack_require__(2).document;
2370// typeof document.createElement is 'object' in old IE
2371var is = isObject(document) && isObject(document.createElement);
2372module.exports = function (it) {
2373 return is ? document.createElement(it) : {};
2374};
2375
2376
2377/***/ }),
2378/* 51 */
2379/***/ (function(module, exports, __webpack_require__) {
2380
2381var has = __webpack_require__(7);
2382var toIObject = __webpack_require__(15);
2383var arrayIndexOf = __webpack_require__(76)(false);
2384var IE_PROTO = __webpack_require__(34)('IE_PROTO');
2385
2386module.exports = function (object, names) {
2387 var O = toIObject(object);
2388 var i = 0;
2389 var result = [];
2390 var key;
2391 for (key in O) if (key != IE_PROTO) has(O, key) && result.push(key);
2392 // Don't enum bug & hidden keys
2393 while (names.length > i) if (has(O, key = names[i++])) {
2394 ~arrayIndexOf(result, key) || result.push(key);
2395 }
2396 return result;
2397};
2398
2399
2400/***/ }),
2401/* 52 */
2402/***/ (function(module, exports, __webpack_require__) {
2403
2404// fallback for non-array-like ES3 and non-enumerable old V8 strings
2405var cof = __webpack_require__(53);
2406// eslint-disable-next-line no-prototype-builtins
2407module.exports = Object('z').propertyIsEnumerable(0) ? Object : function (it) {
2408 return cof(it) == 'String' ? it.split('') : Object(it);
2409};
2410
2411
2412/***/ }),
2413/* 53 */
2414/***/ (function(module, exports) {
2415
2416var toString = {}.toString;
2417
2418module.exports = function (it) {
2419 return toString.call(it).slice(8, -1);
2420};
2421
2422
2423/***/ }),
2424/* 54 */
2425/***/ (function(module, exports, __webpack_require__) {
2426
2427"use strict";
2428
2429
2430exports.__esModule = true;
2431
2432var _iterator = __webpack_require__(79);
2433
2434var _iterator2 = _interopRequireDefault(_iterator);
2435
2436var _symbol = __webpack_require__(91);
2437
2438var _symbol2 = _interopRequireDefault(_symbol);
2439
2440var _typeof = typeof _symbol2.default === "function" && typeof _iterator2.default === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof _symbol2.default === "function" && obj.constructor === _symbol2.default && obj !== _symbol2.default.prototype ? "symbol" : typeof obj; };
2441
2442function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
2443
2444exports.default = typeof _symbol2.default === "function" && _typeof(_iterator2.default) === "symbol" ? function (obj) {
2445 return typeof obj === "undefined" ? "undefined" : _typeof(obj);
2446} : function (obj) {
2447 return obj && typeof _symbol2.default === "function" && obj.constructor === _symbol2.default && obj !== _symbol2.default.prototype ? "symbol" : typeof obj === "undefined" ? "undefined" : _typeof(obj);
2448};
2449
2450/***/ }),
2451/* 55 */
2452/***/ (function(module, exports, __webpack_require__) {
2453
2454"use strict";
2455
2456var LIBRARY = __webpack_require__(25);
2457var $export = __webpack_require__(12);
2458var redefine = __webpack_require__(56);
2459var hide = __webpack_require__(13);
2460var Iterators = __webpack_require__(39);
2461var $iterCreate = __webpack_require__(83);
2462var setToStringTag = __webpack_require__(41);
2463var getPrototypeOf = __webpack_require__(86);
2464var ITERATOR = __webpack_require__(16)('iterator');
2465var BUGGY = !([].keys && 'next' in [].keys()); // Safari has buggy iterators w/o `next`
2466var FF_ITERATOR = '@@iterator';
2467var KEYS = 'keys';
2468var VALUES = 'values';
2469
2470var returnThis = function () { return this; };
2471
2472module.exports = function (Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED) {
2473 $iterCreate(Constructor, NAME, next);
2474 var getMethod = function (kind) {
2475 if (!BUGGY && kind in proto) return proto[kind];
2476 switch (kind) {
2477 case KEYS: return function keys() { return new Constructor(this, kind); };
2478 case VALUES: return function values() { return new Constructor(this, kind); };
2479 } return function entries() { return new Constructor(this, kind); };
2480 };
2481 var TAG = NAME + ' Iterator';
2482 var DEF_VALUES = DEFAULT == VALUES;
2483 var VALUES_BUG = false;
2484 var proto = Base.prototype;
2485 var $native = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT];
2486 var $default = $native || getMethod(DEFAULT);
2487 var $entries = DEFAULT ? !DEF_VALUES ? $default : getMethod('entries') : undefined;
2488 var $anyNative = NAME == 'Array' ? proto.entries || $native : $native;
2489 var methods, key, IteratorPrototype;
2490 // Fix native
2491 if ($anyNative) {
2492 IteratorPrototype = getPrototypeOf($anyNative.call(new Base()));
2493 if (IteratorPrototype !== Object.prototype && IteratorPrototype.next) {
2494 // Set @@toStringTag to native iterators
2495 setToStringTag(IteratorPrototype, TAG, true);
2496 // fix for some old engines
2497 if (!LIBRARY && typeof IteratorPrototype[ITERATOR] != 'function') hide(IteratorPrototype, ITERATOR, returnThis);
2498 }
2499 }
2500 // fix Array#{values, @@iterator}.name in V8 / FF
2501 if (DEF_VALUES && $native && $native.name !== VALUES) {
2502 VALUES_BUG = true;
2503 $default = function values() { return $native.call(this); };
2504 }
2505 // Define iterator
2506 if ((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])) {
2507 hide(proto, ITERATOR, $default);
2508 }
2509 // Plug for library
2510 Iterators[NAME] = $default;
2511 Iterators[TAG] = returnThis;
2512 if (DEFAULT) {
2513 methods = {
2514 values: DEF_VALUES ? $default : getMethod(VALUES),
2515 keys: IS_SET ? $default : getMethod(KEYS),
2516 entries: $entries
2517 };
2518 if (FORCED) for (key in methods) {
2519 if (!(key in proto)) redefine(proto, key, methods[key]);
2520 } else $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods);
2521 }
2522 return methods;
2523};
2524
2525
2526/***/ }),
2527/* 56 */
2528/***/ (function(module, exports, __webpack_require__) {
2529
2530module.exports = __webpack_require__(13);
2531
2532
2533/***/ }),
2534/* 57 */
2535/***/ (function(module, exports, __webpack_require__) {
2536
2537// 19.1.2.7 / 15.2.3.4 Object.getOwnPropertyNames(O)
2538var $keys = __webpack_require__(51);
2539var hiddenKeys = __webpack_require__(36).concat('length', 'prototype');
2540
2541exports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
2542 return $keys(O, hiddenKeys);
2543};
2544
2545
2546/***/ }),
2547/* 58 */
2548/***/ (function(module, exports, __webpack_require__) {
2549
2550var pIE = __webpack_require__(27);
2551var createDesc = __webpack_require__(23);
2552var toIObject = __webpack_require__(15);
2553var toPrimitive = __webpack_require__(31);
2554var has = __webpack_require__(7);
2555var IE8_DOM_DEFINE = __webpack_require__(49);
2556var gOPD = Object.getOwnPropertyDescriptor;
2557
2558exports.f = __webpack_require__(4) ? gOPD : function getOwnPropertyDescriptor(O, P) {
2559 O = toIObject(O);
2560 P = toPrimitive(P, true);
2561 if (IE8_DOM_DEFINE) try {
2562 return gOPD(O, P);
2563 } catch (e) { /* empty */ }
2564 if (has(O, P)) return createDesc(!pIE.f.call(O, P), O[P]);
2565};
2566
2567
2568/***/ }),
2569/* 59 */
2570/***/ (function(module, exports, __webpack_require__) {
2571
2572"use strict";
2573/* WEBPACK VAR INJECTION */(function(process) {
2574
2575if (process.env.NODE_ENV === 'production') {
2576 module.exports = __webpack_require__(111);
2577} else {
2578 module.exports = __webpack_require__(112);
2579}
2580
2581/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17)))
2582
2583/***/ }),
2584/* 60 */
2585/***/ (function(module, __webpack_exports__, __webpack_require__) {
2586
2587"use strict";
2588/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__ = __webpack_require__(0);
2589/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__);
2590/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck__ = __webpack_require__(8);
2591/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck__);
2592/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn__ = __webpack_require__(9);
2593/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn__);
2594/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass__ = __webpack_require__(10);
2595/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass__);
2596/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits__ = __webpack_require__(11);
2597/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits__);
2598/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_react__ = __webpack_require__(1);
2599/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_react__);
2600/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_prop_types__ = __webpack_require__(5);
2601/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_prop_types__);
2602/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_react_dom__ = __webpack_require__(28);
2603/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_react_dom__);
2604/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_lifecycles_compat__ = __webpack_require__(22);
2605/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__util__ = __webpack_require__(21);
2606/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__Tween__ = __webpack_require__(61);
2607/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__ticker__ = __webpack_require__(64);
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622function noop() {}
2623
2624var perFrame = Math.round(1000 / 60);
2625var objectOrArray = __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.oneOfType([__WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.object, __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.array]);
2626
2627var TweenOne = function (_Component) {
2628 __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits___default()(TweenOne, _Component);
2629
2630 __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass___default()(TweenOne, null, [{
2631 key: 'getDerivedStateFromProps',
2632 value: function getDerivedStateFromProps(props, _ref) {
2633 var prevProps = _ref.prevProps,
2634 $self = _ref.$self;
2635
2636 var nextState = {
2637 prevProps: props
2638 };
2639 if (prevProps) {
2640 if (!$self.tween && !$self.dom) {
2641 $self.updateAnim = true;
2642 return;
2643 }
2644
2645 // 动画处理
2646 var newAnimation = props.animation;
2647 var currentAnimation = prevProps.animation;
2648 var equal = Object(__WEBPACK_IMPORTED_MODULE_9__util__["f" /* objectEqual */])(currentAnimation, newAnimation);
2649 if (!equal) {
2650 if (props.resetStyle && $self.tween) {
2651 $self.tween.resetDefaultStyle();
2652 }
2653 $self.updateAnim = true;
2654 }
2655
2656 // 跳帧事件 moment;
2657 var nextMoment = props.moment;
2658 if (typeof nextMoment === 'number' && nextMoment !== prevProps.moment) {
2659
2660 if ($self.tween && !$self.updateAnim) {
2661 $self.startMoment = nextMoment;
2662 $self.startTime = __WEBPACK_IMPORTED_MODULE_11__ticker__["a" /* default */].time;
2663 if (props.paused) {
2664 $self.raf();
2665 }
2666 if ($self.tween.progressTime >= $self.tween.totalTime) {
2667 $self.play();
2668 }
2669 } else {
2670 $self.updateAnim = true;
2671 }
2672 }
2673
2674 // 暂停倒放
2675 if ($self.paused !== props.paused || $self.reverse !== props.reverse) {
2676 $self.paused = props.paused;
2677 $self.reverse = props.reverse;
2678 if ($self.paused) {
2679 $self.cancelRequestAnimationFrame();
2680 } else if ($self.reverse && props.reverseDelay) {
2681 $self.cancelRequestAnimationFrame();
2682 __WEBPACK_IMPORTED_MODULE_11__ticker__["a" /* default */].timeout($self.restart, props.reverseDelay);
2683 } else {
2684 // 在 form 状态下,暂停时拉 moment 时,start 有值恢复播放,在 delay 的时间没有处理。。
2685 if ($self.tween) {
2686 $self.tween.resetAnimData();
2687 $self.tween.resetDefaultStyle();
2688 }
2689 if (!$self.updateAnim) {
2690 $self.restart();
2691 }
2692 }
2693 }
2694
2695 var styleEqual = Object(__WEBPACK_IMPORTED_MODULE_9__util__["f" /* objectEqual */])(prevProps.style, props.style);
2696 if (!styleEqual) {
2697 // 在动画时更改了 style, 作为更改开始数值。
2698 if ($self.tween) {
2699 $self.tween.reStart(props.style, prevProps.style, $self.tween.progressTime < $self.tween.totalTime);
2700 if ($self.paused) {
2701 $self.raf();
2702 }
2703 }
2704 }
2705 $self.setForcedJudg(props);
2706 }
2707 return nextState; // eslint-disable-line
2708 }
2709 }]);
2710
2711 function TweenOne(props) {
2712 __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck___default()(this, TweenOne);
2713
2714 var _this = __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn___default()(this, (TweenOne.__proto__ || Object.getPrototypeOf(TweenOne)).call(this, props));
2715
2716 _initialiseProps.call(_this);
2717
2718 _this.rafID = -1;
2719 _this.paused = props.paused;
2720 _this.reverse = props.reverse;
2721 _this.updateAnim = false;
2722 _this.repeatNum = 0;
2723 _this.forced = {};
2724 _this.currentRef = null;
2725 _this.setForcedJudg(props);
2726 _this.state = {
2727 $self: _this
2728 };
2729 return _this;
2730 }
2731
2732 __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass___default()(TweenOne, [{
2733 key: 'componentDidMount',
2734 value: function componentDidMount() {
2735 this.dom = __WEBPACK_IMPORTED_MODULE_7_react_dom___default.a.findDOMNode(this);
2736 if (this.dom && this.dom.nodeName !== '#text') {
2737 this.start();
2738 }
2739 }
2740 }, {
2741 key: 'componentDidUpdate',
2742 value: function componentDidUpdate() {
2743 if (!this.dom) {
2744 this.dom = __WEBPACK_IMPORTED_MODULE_7_react_dom___default.a.findDOMNode(this);
2745 }
2746 // 样式更新了后再执行动画;
2747 if (this.updateAnim && this.dom && this.dom.nodeName !== '#text') {
2748 if (this.tween) {
2749 this.cancelRequestAnimationFrame();
2750 }
2751 this.start();
2752 }
2753 }
2754 }, {
2755 key: 'componentWillUnmount',
2756 value: function componentWillUnmount() {
2757 this.cancelRequestAnimationFrame();
2758 }
2759
2760 /**
2761 * @method setForcedJudg
2762 * @param props
2763 * QueueAnim 套在组件下面后导至子级变化。
2764 * <QueueAnim component={Menu} >
2765 * <SubMenu key="a" title="导航">
2766 * <Item />
2767 * </SubMenu>
2768 * </QueueAnim>
2769 * rc-Menu 里是以 isXXX 来判断是 rc-Menu 的子级;
2770 * 如: 用 isSubMenu 来处理 hover 事件
2771 * 地址: https://github.com/react-component/menu/blob/master/src/MenuMixin.js#L172
2772 * 暂时方案: 在组件里添加判断用的值。
2773 */
2774
2775 }, {
2776 key: 'render',
2777 value: function render() {
2778 var _this2 = this;
2779
2780 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, this.props);
2781 ['animation', 'component', 'componentProps', 'reverseDelay', 'attr', 'paused', 'reverse', 'repeat', 'yoyo', 'moment', 'resetStyle', 'forcedJudg'].forEach(function (key) {
2782 return delete props[key];
2783 });
2784 props.style = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, this.props.style);
2785 Object.keys(props.style).forEach(function (p) {
2786 if (p.match(/filter/i)) {
2787 ['Webkit', 'Moz', 'Ms', 'ms'].forEach(function (prefix) {
2788 props.style[prefix + 'Filter'] = props.style[p];
2789 });
2790 }
2791 });
2792 // component 为空时调用子级的。。
2793 if (!this.props.component) {
2794 if (!this.props.children) {
2795 return this.props.children;
2796 }
2797 var childrenProps = this.props.children.props;
2798 var style = childrenProps.style,
2799 className = childrenProps.className;
2800 // 合并 style 与 className。
2801
2802 var newStyle = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, style, props.style);
2803 var newClassName = props.className ? props.className + ' ' + className : className;
2804 return __WEBPACK_IMPORTED_MODULE_5_react___default.a.cloneElement(this.props.children, { style: newStyle, className: newClassName });
2805 }
2806 return __WEBPACK_IMPORTED_MODULE_5_react___default.a.createElement(this.props.component, __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({
2807 ref: function ref(c) {
2808 _this2.currentRef = c;
2809 }
2810 }, props, this.props.componentProps));
2811 }
2812 }]);
2813
2814 return TweenOne;
2815}(__WEBPACK_IMPORTED_MODULE_5_react__["Component"]);
2816
2817TweenOne.propTypes = {
2818 component: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
2819 componentProps: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
2820 animation: objectOrArray,
2821 children: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
2822 style: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.object,
2823 paused: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.bool,
2824 reverse: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.bool,
2825 reverseDelay: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.number,
2826 yoyo: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.bool,
2827 repeat: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.number,
2828 moment: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.number,
2829 attr: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.string,
2830 onChange: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.func,
2831 resetStyle: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.bool,
2832 forcedJudg: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.object
2833};
2834TweenOne.defaultProps = {
2835 component: 'div',
2836 componentProps: {},
2837 reverseDelay: 0,
2838 repeat: 0,
2839 attr: 'style',
2840 onChange: noop
2841};
2842
2843var _initialiseProps = function _initialiseProps() {
2844 var _this3 = this;
2845
2846 this.setForcedJudg = function (props) {
2847 Object.keys(_this3.forced).forEach(function (key) {
2848 delete _this3[key];
2849 delete _this3.forced[key];
2850 });
2851 if (props.forcedJudg) {
2852 Object.keys(props.forcedJudg).forEach(function (key) {
2853 if (!_this3[key]) {
2854 _this3[key] = props.forcedJudg[key];
2855 _this3.forced[key] = 1;
2856 }
2857 });
2858 }
2859 };
2860
2861 this.setDefault = function (props) {
2862 _this3.moment = props.moment || 0;
2863 _this3.startMoment = props.moment || 0;
2864 _this3.startTime = __WEBPACK_IMPORTED_MODULE_11__ticker__["a" /* default */].time;
2865 };
2866
2867 this.restart = function () {
2868 if (!_this3.tween) {
2869 return;
2870 }
2871 _this3.startMoment = _this3.moment;
2872 _this3.startTime = __WEBPACK_IMPORTED_MODULE_11__ticker__["a" /* default */].time;
2873 _this3.tween.reverse = _this3.reverse;
2874 _this3.tween.reverseStartTime = _this3.startMoment;
2875 _this3.raf();
2876 _this3.play();
2877 };
2878
2879 this.start = function () {
2880 _this3.updateAnim = false;
2881 var props = _this3.props;
2882 if (props.animation && Object.keys(props.animation).length) {
2883 _this3.setDefault(props);
2884 _this3.tween = new __WEBPACK_IMPORTED_MODULE_10__Tween__["a" /* default */](_this3.dom, props.animation, props.attr);
2885 _this3.tween.reverse = _this3.reverse;
2886 // 预先注册 raf, 初始动画数值。
2887 _this3.raf();
2888 // 开始动画
2889 _this3.play();
2890 } else {
2891 _this3.tween = null;
2892 }
2893 };
2894
2895 this.play = function () {
2896 _this3.cancelRequestAnimationFrame();
2897 if (_this3.paused) {
2898 return;
2899 }
2900 _this3.rafID = __WEBPACK_IMPORTED_MODULE_11__ticker__["a" /* default */].add(_this3.raf);
2901 };
2902
2903 this.frame = function () {
2904 var yoyo = _this3.props.yoyo;
2905 var repeat = _this3.props.repeat;
2906
2907 var totalTime = repeat === -1 ? Number.MAX_VALUE : _this3.tween.totalTime * (repeat + 1);
2908 repeat = repeat >= 0 ? repeat : Number.MAX_VALUE;
2909 var moment = __WEBPACK_IMPORTED_MODULE_11__ticker__["a" /* default */].time - _this3.startTime + _this3.startMoment;
2910 if (_this3.reverse) {
2911 moment = (_this3.startMoment || 0) - (__WEBPACK_IMPORTED_MODULE_11__ticker__["a" /* default */].time - _this3.startTime);
2912 }
2913 moment = moment > totalTime ? totalTime : moment;
2914 moment = moment <= 0 ? 0 : moment;
2915 var repeatNum = Math.floor(moment / _this3.tween.totalTime) || 0;
2916 repeatNum = repeatNum > repeat ? repeat : repeatNum;
2917 var tweenMoment = moment - _this3.tween.totalTime * repeatNum;
2918 tweenMoment = tweenMoment < perFrame && !_this3.reverse && totalTime >= perFrame ? 0 : tweenMoment;
2919 if (repeat && moment && moment - _this3.tween.totalTime * repeatNum < perFrame) {
2920 // 在重置样式之前补 complete;
2921 _this3.tween.frame(_this3.tween.totalTime * repeatNum);
2922 }
2923 if (moment < _this3.moment && !_this3.reverse || repeat !== 0 && repeatNum && repeatNum !== _this3.repeatNum) {
2924 // 在 form 状态下,暂停时拉 moment 时,start 有值,,往返方向播放时,在 delay 的时间没有处理。。
2925 // 与上面的处理一样,删除 start ,重新走一遍 start。。
2926 _this3.tween.resetAnimData();
2927 _this3.tween.resetDefaultStyle();
2928 }
2929 var yoyoReverse = yoyo && repeatNum % 2;
2930 if (yoyoReverse) {
2931 tweenMoment = _this3.tween.totalTime - tweenMoment;
2932 }
2933 _this3.tween.onChange = function (e) {
2934 var cb = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, e, {
2935 timelineMode: ''
2936 });
2937
2938 if (_this3.moment === _this3.startMoment && !_this3.reverse && !e.index && e.mode === 'onStart' || _this3.reverse) {
2939 cb.timelineMode = 'onTimelineStart';
2940 } else if (moment >= totalTime && !_this3.reverse || !moment && _this3.reverse) {
2941 cb.timelineMode = 'onTimelineComplete';
2942 } else if (repeatNum !== _this3.timelineRepeatNum) {
2943 cb.timelineMode = 'onTimelineRepeat';
2944 } else {
2945 cb.timelineMode = 'onTimelineUpdate';
2946 }
2947 _this3.timelineRepeatNum = repeatNum;
2948 _this3.props.onChange(cb);
2949 };
2950 _this3.moment = moment;
2951 _this3.repeatNum = repeatNum;
2952 _this3.tween.frame(tweenMoment);
2953 };
2954
2955 this.raf = function () {
2956 var tween = _this3.tween;
2957 _this3.frame();
2958 if (tween !== _this3.tween) {
2959 // 在 onComplete 时更换动画时,raf 没结束,所以需要强制退出,避逸两个时间的冲突。
2960 return null;
2961 }
2962 var repeat = _this3.props.repeat;
2963
2964 var totalTime = repeat === -1 ? Number.MAX_VALUE : _this3.tween.totalTime * (repeat + 1);
2965 if (_this3.moment >= totalTime && !_this3.reverse || _this3.paused || _this3.reverse && _this3.moment === 0) {
2966 return _this3.cancelRequestAnimationFrame();
2967 }
2968 return null;
2969 };
2970
2971 this.cancelRequestAnimationFrame = function () {
2972 __WEBPACK_IMPORTED_MODULE_11__ticker__["a" /* default */].clear(_this3.rafID);
2973 _this3.rafID = -1;
2974 };
2975};
2976
2977TweenOne.isTweenOne = true;
2978/* harmony default export */ __webpack_exports__["a"] = (Object(__WEBPACK_IMPORTED_MODULE_8_react_lifecycles_compat__["a" /* polyfill */])(TweenOne));
2979
2980/***/ }),
2981/* 61 */
2982/***/ (function(module, __webpack_exports__, __webpack_require__) {
2983
2984"use strict";
2985/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__ = __webpack_require__(0);
2986/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__);
2987/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_style_utils__ = __webpack_require__(29);
2988/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_style_utils___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_style_utils__);
2989/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__easing__ = __webpack_require__(62);
2990/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__plugins__ = __webpack_require__(46);
2991/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__plugin_StylePlugin__ = __webpack_require__(117);
2992/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__util_js__ = __webpack_require__(21);
2993
2994/* eslint-disable func-names */
2995/**
2996 * Created by jljsj on 16/1/27.
2997 */
2998
2999
3000
3001
3002
3003
3004
3005var DEFAULT_EASING = 'easeInOutQuad';
3006var DEFAULT_DURATION = 450;
3007var DEFAULT_DELAY = 0;
3008function noop() {}
3009__WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */].push(__WEBPACK_IMPORTED_MODULE_4__plugin_StylePlugin__["a" /* default */]);
3010// 设置默认数据
3011function defaultData(vars, now) {
3012 var duration = vars.duration || vars.duration === 0 ? vars.duration : DEFAULT_DURATION;
3013 return {
3014 duration: vars.type === 'set' ? 0 : duration,
3015 delay: vars.delay || DEFAULT_DELAY,
3016 ease: typeof vars.ease === 'function' ? vars.ease : __WEBPACK_IMPORTED_MODULE_2__easing__["a" /* default */][vars.ease || DEFAULT_EASING],
3017 onUpdate: vars.onUpdate || noop,
3018 onComplete: vars.onComplete || noop,
3019 onStart: vars.onStart || noop,
3020 onRepeat: vars.onRepeat || noop,
3021 repeat: vars.repeat || 0,
3022 repeatDelay: vars.repeatDelay || 0,
3023 yoyo: vars.yoyo || false,
3024 type: vars.type === 'from' ? 'from' : 'to',
3025 initTime: now,
3026 appearTo: typeof vars.appearTo === 'number' ? vars.appearTo : null,
3027 perTime: 0,
3028 currentRepeat: 0
3029 };
3030}
3031
3032var Tween = function Tween(target, to, attr) {
3033 var toData = Object(__WEBPACK_IMPORTED_MODULE_5__util_js__["a" /* dataToArray */])(to);
3034 this.target = target;
3035 this.attr = attr || 'style';
3036 // 时间精度补齐;
3037 this.accuracy = 0.00001;
3038 // 记录总时间;
3039 this.totalTime = 0;
3040 // 记录当前时间;
3041 this.progressTime = 0;
3042 // 记录时间轴数据;
3043 this.defaultData = [];
3044 // 每个的开始数据;
3045 this.start = {};
3046 // 开始默认的数据;
3047 this.startDefaultData = {};
3048 // 动画过程
3049 this.tween = {};
3050 // toData;
3051 this.data = toData;
3052 // 每帧的时间;
3053 this.perFrame = Math.round(1000 / 60);
3054 // 注册,第一次进入执行注册
3055 this.register = false;
3056 // svg元素
3057 this.isSvg = this.target.ownerSVGElement;
3058 // 设置 style
3059 var data = this.setAttrIsStyle();
3060 // 设置默认动画数据;
3061 this.setDefaultData(data);
3062};
3063var p = Tween.prototype;
3064p.setAttrIsStyle = function () {
3065 var _this = this;
3066
3067 var data = [];
3068 var defaultParam = defaultData({}, 0);
3069 this.data.forEach(function (d, i) {
3070 var _d = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, d);
3071 if (_this.attr === 'style') {
3072 data[i] = {};
3073 Object.keys(_d).forEach(function (key) {
3074 if (key in defaultParam) {
3075 data[i][key] = _d[key];
3076 delete _d[key];
3077 }
3078 });
3079 data[i].style = _d;
3080 _this.startDefaultData.style = _this.target.getAttribute('style') || '';
3081 } else if (_this.attr === 'attr') {
3082 Object.keys(_d).forEach(function (key) {
3083 if (key === 'style' && Array.isArray(d[key])) {
3084 throw new Error('Style should be the object.');
3085 }
3086 if (key === 'bezier') {
3087 _d.style = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, _d.style, { bezier: _d[key] });
3088 delete _d[key];
3089 _this.startDefaultData.style = _this.target.getAttribute('style') || '';
3090 } else {
3091 if (key in defaultParam) {
3092 return;
3093 }
3094 _this.startDefaultData[key] = _this.getValue(key);
3095 }
3096 });
3097 data[i] = _d;
3098 }
3099 });
3100 return data;
3101};
3102p.setDefaultData = function (_vars) {
3103 var _this2 = this;
3104
3105 var now = 0;
3106 var repeatMax = false;
3107 var data = _vars.map(function (item) {
3108 var appearToBool = typeof item.appearTo === 'number';
3109 // 加上延时,在没有播放过时;
3110 if (!appearToBool) {
3111 now += item.delay || 0;
3112 }
3113 var appearToTime = (item.appearTo || 0) + (item.delay || 0);
3114 // 获取默认数据
3115 var tweenData = defaultData(item, appearToBool ? appearToTime : now);
3116 tweenData.vars = {};
3117 Object.keys(item).forEach(function (_key) {
3118 if (!(_key in tweenData)) {
3119 var _data = item[_key];
3120 if (_key in __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */]) {
3121 tweenData.vars[_key] = new __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */][_key](_this2.target, _data, tweenData.type);
3122 } else if ((_key === 'd' || _key === 'points') && 'SVGMorph' in __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */]) {
3123 tweenData.vars[_key] = new __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */].SVGMorph(_this2.target, _data, _key);
3124 } else if (_key.match(/color/i) || _key === 'stroke' || _key === 'fill') {
3125 tweenData.vars[_key] = { type: 'color', vars: Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["parseColor"])(_data) };
3126 } else if (typeof _data === 'number' || _data.split(/[,|\s]/g).length <= 1) {
3127 var vars = parseFloat(_data);
3128 var unit = _data.toString().replace(/[^a-z|%]/g, '');
3129 var count = _data.toString().replace(/[^+|=|-]/g, '');
3130 tweenData.vars[_key] = { unit: unit, vars: vars, count: count };
3131 }
3132 }
3133 });
3134 if (tweenData.yoyo && !tweenData.repeat) {
3135 console.warn('Warning: yoyo must be used together with repeat;'); // eslint-disable-line
3136 }
3137 if (tweenData.repeat === -1) {
3138 repeatMax = true;
3139 }
3140 var repeat = tweenData.repeat === -1 ? 0 : tweenData.repeat;
3141 if (appearToBool) {
3142 // 如果有 appearTo 且这条时间比 now 大时,,总时间用这条;
3143 var appearNow = item.appearTo + (item.delay || 0) + tweenData.duration * (repeat + 1) + tweenData.repeatDelay * repeat;
3144 now = appearNow >= now ? appearNow : now;
3145 } else if (tweenData.delay < -tweenData.duration) {
3146 // 如果延时小于 负时间时,,不加,再减回延时;
3147 now -= tweenData.delay;
3148 } else {
3149 // repeat 为 -1 只记录一次。不能跟 reverse 同时使用;
3150 now += tweenData.duration * (repeat + 1) + tweenData.repeatDelay * repeat;
3151 }
3152 tweenData.mode = '';
3153 return tweenData;
3154 });
3155 this.totalTime = repeatMax ? Number.MAX_VALUE : now;
3156 this.defaultData = data;
3157};
3158p.getComputedStyle = function () {
3159 var style = typeof window !== 'undefined' && document.defaultView ? document.defaultView.getComputedStyle(this.target) : {};
3160 // 如果是 SVG, 样式全部提出为 transformSVG, 兼容 safari 不能获取 transform;
3161 if (this.isSvg) {
3162 var transform = style[Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["checkStyleName"])('transform')] || 'none';
3163 if (transform === 'none') {
3164 var attrStyle = this.target.getAttribute('style');
3165 if (attrStyle && attrStyle.indexOf('transform:') >= 0) {
3166 transform = attrStyle.split(';').filter(function (k) {
3167 return k.indexOf('transform:') >= 0;
3168 }).map(function (item) {
3169 return Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["createMatrix"])(item.split(':')[1].trim()).toString();
3170 })[0];
3171 } else if (this.target.getAttribute('transform')) {
3172 // 暂时不支持标签上的 transform,后期增加;
3173 console.warn('Do not add transform on the label, otherwise it will be invalid.'); // eslint-disable-line no-console
3174 }
3175 }
3176 style.transformSVG = transform;
3177 }
3178 return style;
3179};
3180p.getAnimStartData = function (item) {
3181 var _this3 = this;
3182
3183 var start = {};
3184 Object.keys(item).forEach(function (_key) {
3185 if (_key in __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */] || _this3.attr === 'attr' && (_key === 'd' || _key === 'points')) {
3186 _this3.computedStyle = _this3.computedStyle || (!_this3.target.getAttribute ? __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, _this3.target) : _this3.getComputedStyle());
3187 start[_key] = item[_key].getAnimStart(_this3.computedStyle, _this3.tween, _this3.isSvg);
3188 return;
3189 }
3190 if (_this3.attr === 'attr') {
3191 // 除了d和这points外的标签动画;
3192 var attribute = _this3.getValue(_key);
3193 var data = attribute === 'null' || !attribute ? 0 : attribute;
3194 if (_key.match(/color/i) || _key === 'stroke' || _key === 'fill') {
3195 data = !data && _key === 'stroke' ? 'rgba(255, 255, 255, 0)' : data;
3196 data = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["parseColor"])(data);
3197 start[_key] = data;
3198 } else if (parseFloat(data) || parseFloat(data) === 0 || data === 0) {
3199 var unit = data.toString().replace(/[^a-z|%]/g, '');
3200 start[_key] = unit !== item[_key].unit ? Object(__WEBPACK_IMPORTED_MODULE_5__util_js__["h" /* startConvertToEndUnit */])(_this3.target, _key, parseFloat(data), unit, item[_key].unit) : parseFloat(data);
3201 }
3202 return;
3203 }
3204 start[_key] = _this3.target[_key] || 0;
3205 });
3206 return start;
3207};
3208p.setAnimData = function (data) {
3209 var _this4 = this;
3210
3211 Object.keys(data).forEach(function (key) {
3212 if (key in __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */] || _this4.attr === 'attr' && (key === 'd' || key === 'points')) {
3213 return;
3214 }
3215 _this4.target[key] = data[key];
3216 });
3217};
3218p.setRatio = function (ratio, endData, i) {
3219 var _this5 = this;
3220
3221 Object.keys(endData.vars).forEach(function (_key) {
3222 if (_key in __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */] || _this5.attr === 'attr' && (_key === 'd' || _key === 'points')) {
3223 endData.vars[_key].setRatio(ratio, _this5.tween, _this5.isSvg && _this5.computedStyle);
3224 return;
3225 }
3226 var endVars = endData.vars[_key];
3227 var startVars = _this5.start[i][_key];
3228 var data = void 0;
3229 if (_this5.attr === 'attr') {
3230 // 除了d和这points外的标签动画;
3231 if (!endVars.type) {
3232 data = endVars.unit.charAt(1) === '=' ? startVars + endVars.vars * ratio + endVars.unit : (endVars.vars - startVars) * ratio + startVars + endVars.unit;
3233 _this5.setValue(_key, endVars.unit ? data : parseFloat(data));
3234 } else if (endVars.type === 'color') {
3235 if (endVars.vars.length === 3 && startVars.length === 4) {
3236 endVars.vars[3] = 1;
3237 }
3238 data = endVars.vars.map(function (_endData, _i) {
3239 var startData = startVars[_i] || 0;
3240 return (_endData - startData) * ratio + startData;
3241 });
3242 _this5.setValue(_key, Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["getColor"])(data));
3243 }
3244 }
3245 });
3246 this.setAnimData(this.tween);
3247};
3248p.getValue = function (key) {
3249 return this.target.getAttribute ? this.target.getAttribute(key) : this.target[key];
3250};
3251p.setValue = function (key, value) {
3252 if (this.target.setAttribute) {
3253 this.target.setAttribute(key, value);
3254 } else {
3255 this.target[key] = value;
3256 }
3257};
3258p.render = function () {
3259 var _this6 = this;
3260
3261 var reverse = this.reverse;
3262 this.defaultData.forEach(function (item, i) {
3263 var initTime = item.initTime;
3264 var duration = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["toFixed"])(item.duration);
3265 // 处理 yoyo 和 repeat; yoyo 是在时间轴上的, 并不是倒放
3266 var repeatNum = Math.ceil((_this6.progressTime - initTime) / (duration + item.repeatDelay)) - 1 || 0;
3267 repeatNum = repeatNum < 0 ? 0 : repeatNum;
3268 if (item.repeat) {
3269 if (item.repeat < repeatNum && item.repeat !== -1) {
3270 return;
3271 }
3272 if (item.repeat || item.repeat <= repeatNum) {
3273 initTime += repeatNum * (duration + item.repeatDelay);
3274 }
3275 }
3276 var startData = item.yoyo && repeatNum % 2 ? 1 : 0;
3277 var endData = item.yoyo && repeatNum % 2 ? 0 : 1;
3278 startData = item.type === 'from' ? 1 - startData : startData;
3279 endData = item.type === 'from' ? 1 - endData : endData;
3280 // 精度损失,只取小数点后10位。
3281 var progressTime = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["toFixed"])(_this6.progressTime - initTime);
3282
3283 var ratio = void 0;
3284
3285 // 开始注册;
3286 // from 时需先执行参数位置;
3287 var fromDelay = item.type === 'from' ? item.delay : 0;
3288 if (progressTime + fromDelay >= 0) {
3289 if (!_this6.start[i]) {
3290 // 设置 start
3291 _this6.start[i] = _this6.getAnimStartData(item.vars);
3292 if (progressTime < _this6.perFrame) {
3293 ratio = !item.duration && !item.delay ? item.ease(1, startData, endData, 1) : item.ease(0, startData, endData, 1);
3294 _this6.setRatio(ratio, item, i);
3295 } else if (progressTime > duration) {
3296 ratio = item.ease(1, startData, endData, 1);
3297 _this6.setRatio(ratio, item, i);
3298 }
3299 if (!_this6.register || i && !initTime) {
3300 _this6.register = true;
3301 if (progressTime === 0 && item.duration && item.delay) {
3302 return;
3303 }
3304 }
3305 }
3306 }
3307
3308 var e = {
3309 index: i,
3310 target: _this6.target
3311 };
3312 var cb = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({
3313 moment: _this6.progressTime
3314 }, e);
3315 var maxPer = _this6.perFrame - _this6.accuracy;
3316 var startTime = item.delay && reverse ? -maxPer : 0;
3317 if ((progressTime >= startTime && !(progressTime > duration && item.mode === 'onComplete') || progressTime < startTime && item.mode && item.mode !== 'onStart') && _this6.start[i]) {
3318 var updateAnim = _this6.updateAnim === 'update';
3319 progressTime = progressTime < maxPer && !reverse && item.duration >= _this6.perFrame ? 0 : progressTime;
3320 if ((progressTime >= duration - _this6.accuracy && !reverse || reverse && progressTime <= 0) && repeatNum >= item.repeat) {
3321 if (item.mode === 'onComplete') {
3322 return;
3323 }
3324 // onReveresComplete 和 onComplete 统一用 onComplete;
3325 ratio = item.ease(reverse ? 0 : 1, startData, endData, 1);
3326 _this6.setRatio(ratio, item, i, item.currentRepeat !== repeatNum);
3327 if ((!item.reset || item.reset && progressTime >= duration) && !updateAnim) {
3328 // duration 为 0 时的一个回调;
3329 if (duration < maxPer) {
3330 if (!duration) {
3331 item.onStart(e);
3332 cb.mode = 'onStart';
3333 _this6.onChange(cb);
3334 }
3335 item.onUpdate(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({ ratio: ratio }, e));
3336 cb.mode = 'onUpdate';
3337 _this6.onChange(cb);
3338 }
3339 item.onComplete(e);
3340 } else if (progressTime >= duration + maxPer) {
3341 return;
3342 }
3343 item.mode = 'onComplete';
3344 } else if (duration > maxPer) {
3345 var currentProgress = progressTime < 0 ? 0 : progressTime;
3346 currentProgress = currentProgress > duration ? duration : currentProgress;
3347 ratio = item.ease(currentProgress, startData, endData, duration);
3348 _this6.setRatio(ratio, item, i);
3349 if (!updateAnim) {
3350 if (item.repeat && repeatNum > 0 && item.currentRepeat !== repeatNum) {
3351 item.mode = 'onRepeat';
3352 item.currentRepeat = repeatNum;
3353 item.onRepeat(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, e, { repeatNum: repeatNum }));
3354 } else if ((item.perTime <= 0 || reverse && item.perTime >= _this6.reverseStartTime - initTime) && item.mode !== 'onStart') {
3355 // onReveresStart 和 onStart 统一用 onStart;
3356 item.mode = 'onStart';
3357 item.onStart(e);
3358 } else {
3359 item.mode = 'onUpdate';
3360 item.onUpdate(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({ ratio: ratio }, e));
3361 }
3362 }
3363 }
3364
3365 if (!updateAnim) {
3366 cb.mode = item.mode;
3367 _this6.onChange(cb);
3368 }
3369 item.perTime = progressTime;
3370 if (item.reset) {
3371 delete item.reset;
3372 }
3373 }
3374 });
3375};
3376// 播放帧
3377p.frame = function (moment) {
3378 var _this7 = this;
3379
3380 this.progressTime = moment;
3381 this.defaultData.forEach(function (item) {
3382 var t = _this7.progressTime - item.duration - item.initTime;
3383 if (t < _this7.perFrame && t > 0) {
3384 _this7.progressTime = item.duration + item.initTime;
3385 }
3386 });
3387 this.render();
3388};
3389
3390p.init = p.frame;
3391
3392p.resetAnimData = function () {
3393 this.tween = {};
3394 this.start = {};
3395};
3396
3397var getDefaultStyle = function getDefaultStyle(domStyle, defaultStyle, tweenData) {
3398 var $data = defaultData({}, 0);
3399 var getStyleToArray = function getStyleToArray(styleString) {
3400 return styleString.split(';').filter(function (c) {
3401 return c;
3402 }).map(function (str) {
3403 return str.split(':').map(function (s) {
3404 return s.trim();
3405 });
3406 });
3407 };
3408 var styleToArray = getStyleToArray(defaultStyle);
3409 var domStyleToArray = getStyleToArray(domStyle);
3410 tweenData.forEach(function (value) {
3411 Object.keys(value).forEach(function (name) {
3412 if (!(name in $data)) {
3413 var styleName = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["toCssLowerCase"])(Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["isTransform"])(Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["getGsapType"])(name)));
3414 domStyleToArray = domStyleToArray.filter(function (item) {
3415 if (__WEBPACK_IMPORTED_MODULE_5__util_js__["l" /* transformOrFilter */][item[0]] && __WEBPACK_IMPORTED_MODULE_5__util_js__["l" /* transformOrFilter */][styleName]) {
3416 return false;
3417 }
3418 return item[0] !== styleName;
3419 });
3420 }
3421 });
3422 });
3423 styleToArray.forEach(function (item) {
3424 domStyleToArray = domStyleToArray.filter(function ($item) {
3425 if ($item[0] === item[0]) {
3426 return false;
3427 }
3428 return true;
3429 });
3430 });
3431 return styleToArray.concat(domStyleToArray).map(function (item) {
3432 return item.join(':');
3433 }).join(';');
3434};
3435
3436p.resetDefaultStyle = function () {
3437 var _this8 = this;
3438
3439 this.tween = {};
3440 this.defaultData = this.defaultData.map(function (item) {
3441 item.reset = true;
3442 delete item.mode;
3443 return item;
3444 });
3445 var data = defaultData({}, 0);
3446 Object.keys(this.startDefaultData).forEach(function (key) {
3447 if (!(key in data)) {
3448 if (key === 'style') {
3449 var value = getDefaultStyle(_this8.target.style.cssText, _this8.startDefaultData.style, _this8.data);
3450 _this8.setValue(key, value);
3451 } else {
3452 _this8.setValue(key, _this8.startDefaultData[key]);
3453 }
3454 _this8.computedStyle = null;
3455 }
3456 });
3457};
3458
3459p.reStart = function (style, preStyle, isTween) {
3460 var _this9 = this;
3461
3462 this.start = {};
3463 this.tween = {};
3464 Object.keys(style || {}).forEach(function (key) {
3465 if (isTween || !preStyle || style[key] !== preStyle[key]) {
3466 _this9.target.style[key] = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["stylesToCss"])(key, style[key]);
3467 }
3468 });
3469 this.setAttrIsStyle();
3470 this.computedStyle = null;
3471};
3472
3473p.onChange = noop;
3474/* harmony default export */ __webpack_exports__["a"] = (Tween);
3475
3476/***/ }),
3477/* 62 */
3478/***/ (function(module, __webpack_exports__, __webpack_require__) {
3479
3480"use strict";
3481/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tween_functions__ = __webpack_require__(63);
3482/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tween_functions___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_tween_functions__);
3483/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__util__ = __webpack_require__(21);
3484
3485
3486
3487__WEBPACK_IMPORTED_MODULE_0_tween_functions___default.a.path = function (_path, _param) {
3488 var param = _param || {};
3489 if (__WEBPACK_IMPORTED_MODULE_1__util__["m" /* windowIsUndefined */]) {
3490 return 'linear';
3491 }
3492 var pathNode = Object(__WEBPACK_IMPORTED_MODULE_1__util__["g" /* parsePath */])(_path);
3493 var pathLength = pathNode.getTotalLength();
3494 var rect = param.rect || 100; // path 的大小,100 * 100,
3495 var lengthPixel = param.lengthPixel || 200; // 线上取点像素,默认分为 200 段。。
3496 var points = [];
3497 for (var i = 0; i < lengthPixel - 1; i++) {
3498 points.push(pathNode.getPointAtLength(pathLength / (lengthPixel - 1) * i));
3499 }
3500 points.push(pathNode.getPointAtLength(lengthPixel));
3501 return function path(t, b, _c, d) {
3502 var p = __WEBPACK_IMPORTED_MODULE_0_tween_functions___default.a.linear(t, b, _c, d);
3503 var timePointX = rect * p; // X 轴的百分比;
3504 // 取出 x 轴百分比上的点;
3505 var point = points.filter(function (item) {
3506 return item.x >= timePointX;
3507 })[0] || pathNode.getPointAtLength(p * pathLength);
3508 return 1 - point.y / rect;
3509 };
3510};
3511
3512/* harmony default export */ __webpack_exports__["a"] = (__WEBPACK_IMPORTED_MODULE_0_tween_functions___default.a);
3513
3514/***/ }),
3515/* 63 */
3516/***/ (function(module, exports, __webpack_require__) {
3517
3518"use strict";
3519
3520
3521// t: current time, b: beginning value, _c: final value, d: total duration
3522var tweenFunctions = {
3523 linear: function(t, b, _c, d) {
3524 var c = _c - b;
3525 return c * t / d + b;
3526 },
3527 easeInQuad: function(t, b, _c, d) {
3528 var c = _c - b;
3529 return c * (t /= d) * t + b;
3530 },
3531 easeOutQuad: function(t, b, _c, d) {
3532 var c = _c - b;
3533 return -c * (t /= d) * (t - 2) + b;
3534 },
3535 easeInOutQuad: function(t, b, _c, d) {
3536 var c = _c - b;
3537 if ((t /= d / 2) < 1) {
3538 return c / 2 * t * t + b;
3539 } else {
3540 return -c / 2 * ((--t) * (t - 2) - 1) + b;
3541 }
3542 },
3543 easeInCubic: function(t, b, _c, d) {
3544 var c = _c - b;
3545 return c * (t /= d) * t * t + b;
3546 },
3547 easeOutCubic: function(t, b, _c, d) {
3548 var c = _c - b;
3549 return c * ((t = t / d - 1) * t * t + 1) + b;
3550 },
3551 easeInOutCubic: function(t, b, _c, d) {
3552 var c = _c - b;
3553 if ((t /= d / 2) < 1) {
3554 return c / 2 * t * t * t + b;
3555 } else {
3556 return c / 2 * ((t -= 2) * t * t + 2) + b;
3557 }
3558 },
3559 easeInQuart: function(t, b, _c, d) {
3560 var c = _c - b;
3561 return c * (t /= d) * t * t * t + b;
3562 },
3563 easeOutQuart: function(t, b, _c, d) {
3564 var c = _c - b;
3565 return -c * ((t = t / d - 1) * t * t * t - 1) + b;
3566 },
3567 easeInOutQuart: function(t, b, _c, d) {
3568 var c = _c - b;
3569 if ((t /= d / 2) < 1) {
3570 return c / 2 * t * t * t * t + b;
3571 } else {
3572 return -c / 2 * ((t -= 2) * t * t * t - 2) + b;
3573 }
3574 },
3575 easeInQuint: function(t, b, _c, d) {
3576 var c = _c - b;
3577 return c * (t /= d) * t * t * t * t + b;
3578 },
3579 easeOutQuint: function(t, b, _c, d) {
3580 var c = _c - b;
3581 return c * ((t = t / d - 1) * t * t * t * t + 1) + b;
3582 },
3583 easeInOutQuint: function(t, b, _c, d) {
3584 var c = _c - b;
3585 if ((t /= d / 2) < 1) {
3586 return c / 2 * t * t * t * t * t + b;
3587 } else {
3588 return c / 2 * ((t -= 2) * t * t * t * t + 2) + b;
3589 }
3590 },
3591 easeInSine: function(t, b, _c, d) {
3592 var c = _c - b;
3593 return -c * Math.cos(t / d * (Math.PI / 2)) + c + b;
3594 },
3595 easeOutSine: function(t, b, _c, d) {
3596 var c = _c - b;
3597 return c * Math.sin(t / d * (Math.PI / 2)) + b;
3598 },
3599 easeInOutSine: function(t, b, _c, d) {
3600 var c = _c - b;
3601 return -c / 2 * (Math.cos(Math.PI * t / d) - 1) + b;
3602 },
3603 easeInExpo: function(t, b, _c, d) {
3604 var c = _c - b;
3605 return (t==0) ? b : c * Math.pow(2, 10 * (t/d - 1)) + b;
3606 },
3607 easeOutExpo: function(t, b, _c, d) {
3608 var c = _c - b;
3609 return (t==d) ? b+c : c * (-Math.pow(2, -10 * t/d) + 1) + b;
3610 },
3611 easeInOutExpo: function(t, b, _c, d) {
3612 var c = _c - b;
3613 if (t === 0) {
3614 return b;
3615 }
3616 if (t === d) {
3617 return b + c;
3618 }
3619 if ((t /= d / 2) < 1) {
3620 return c / 2 * Math.pow(2, 10 * (t - 1)) + b;
3621 } else {
3622 return c / 2 * (-Math.pow(2, -10 * --t) + 2) + b;
3623 }
3624 },
3625 easeInCirc: function(t, b, _c, d) {
3626 var c = _c - b;
3627 return -c * (Math.sqrt(1 - (t /= d) * t) - 1) + b;
3628 },
3629 easeOutCirc: function(t, b, _c, d) {
3630 var c = _c - b;
3631 return c * Math.sqrt(1 - (t = t / d - 1) * t) + b;
3632 },
3633 easeInOutCirc: function(t, b, _c, d) {
3634 var c = _c - b;
3635 if ((t /= d / 2) < 1) {
3636 return -c / 2 * (Math.sqrt(1 - t * t) - 1) + b;
3637 } else {
3638 return c / 2 * (Math.sqrt(1 - (t -= 2) * t) + 1) + b;
3639 }
3640 },
3641 easeInElastic: function(t, b, _c, d) {
3642 var c = _c - b;
3643 var a, p, s;
3644 s = 1.70158;
3645 p = 0;
3646 a = c;
3647 if (t === 0) {
3648 return b;
3649 } else if ((t /= d) === 1) {
3650 return b + c;
3651 }
3652 if (!p) {
3653 p = d * 0.3;
3654 }
3655 if (a < Math.abs(c)) {
3656 a = c;
3657 s = p / 4;
3658 } else {
3659 s = p / (2 * Math.PI) * Math.asin(c / a);
3660 }
3661 return -(a * Math.pow(2, 10 * (t -= 1)) * Math.sin((t * d - s) * (2 * Math.PI) / p)) + b;
3662 },
3663 easeOutElastic: function(t, b, _c, d) {
3664 var c = _c - b;
3665 var a, p, s;
3666 s = 1.70158;
3667 p = 0;
3668 a = c;
3669 if (t === 0) {
3670 return b;
3671 } else if ((t /= d) === 1) {
3672 return b + c;
3673 }
3674 if (!p) {
3675 p = d * 0.3;
3676 }
3677 if (a < Math.abs(c)) {
3678 a = c;
3679 s = p / 4;
3680 } else {
3681 s = p / (2 * Math.PI) * Math.asin(c / a);
3682 }
3683 return a * Math.pow(2, -10 * t) * Math.sin((t * d - s) * (2 * Math.PI) / p) + c + b;
3684 },
3685 easeInOutElastic: function(t, b, _c, d) {
3686 var c = _c - b;
3687 var a, p, s;
3688 s = 1.70158;
3689 p = 0;
3690 a = c;
3691 if (t === 0) {
3692 return b;
3693 } else if ((t /= d / 2) === 2) {
3694 return b + c;
3695 }
3696 if (!p) {
3697 p = d * (0.3 * 1.5);
3698 }
3699 if (a < Math.abs(c)) {
3700 a = c;
3701 s = p / 4;
3702 } else {
3703 s = p / (2 * Math.PI) * Math.asin(c / a);
3704 }
3705 if (t < 1) {
3706 return -0.5 * (a * Math.pow(2, 10 * (t -= 1)) * Math.sin((t * d - s) * (2 * Math.PI) / p)) + b;
3707 } else {
3708 return a * Math.pow(2, -10 * (t -= 1)) * Math.sin((t * d - s) * (2 * Math.PI) / p) * 0.5 + c + b;
3709 }
3710 },
3711 easeInBack: function(t, b, _c, d, s) {
3712 var c = _c - b;
3713 if (s === void 0) {
3714 s = 1.70158;
3715 }
3716 return c * (t /= d) * t * ((s + 1) * t - s) + b;
3717 },
3718 easeOutBack: function(t, b, _c, d, s) {
3719 var c = _c - b;
3720 if (s === void 0) {
3721 s = 1.70158;
3722 }
3723 return c * ((t = t / d - 1) * t * ((s + 1) * t + s) + 1) + b;
3724 },
3725 easeInOutBack: function(t, b, _c, d, s) {
3726 var c = _c - b;
3727 if (s === void 0) {
3728 s = 1.70158;
3729 }
3730 if ((t /= d / 2) < 1) {
3731 return c / 2 * (t * t * (((s *= 1.525) + 1) * t - s)) + b;
3732 } else {
3733 return c / 2 * ((t -= 2) * t * (((s *= 1.525) + 1) * t + s) + 2) + b;
3734 }
3735 },
3736 easeInBounce: function(t, b, _c, d) {
3737 var c = _c - b;
3738 var v;
3739 v = tweenFunctions.easeOutBounce(d - t, 0, c, d);
3740 return c - v + b;
3741 },
3742 easeOutBounce: function(t, b, _c, d) {
3743 var c = _c - b;
3744 if ((t /= d) < 1 / 2.75) {
3745 return c * (7.5625 * t * t) + b;
3746 } else if (t < 2 / 2.75) {
3747 return c * (7.5625 * (t -= 1.5 / 2.75) * t + 0.75) + b;
3748 } else if (t < 2.5 / 2.75) {
3749 return c * (7.5625 * (t -= 2.25 / 2.75) * t + 0.9375) + b;
3750 } else {
3751 return c * (7.5625 * (t -= 2.625 / 2.75) * t + 0.984375) + b;
3752 }
3753 },
3754 easeInOutBounce: function(t, b, _c, d) {
3755 var c = _c - b;
3756 var v;
3757 if (t < d / 2) {
3758 v = tweenFunctions.easeInBounce(t * 2, 0, c, d);
3759 return v * 0.5 + b;
3760 } else {
3761 v = tweenFunctions.easeOutBounce(t * 2 - d, 0, c, d);
3762 return v * 0.5 + c * 0.5 + b;
3763 }
3764 }
3765};
3766
3767module.exports = tweenFunctions;
3768
3769
3770/***/ }),
3771/* 64 */
3772/***/ (function(module, __webpack_exports__, __webpack_require__) {
3773
3774"use strict";
3775/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_raf__ = __webpack_require__(118);
3776/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_raf___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_raf__);
3777/* eslint-disable func-names */
3778
3779
3780var getTime = Date.now || function () {
3781 return new Date().getTime();
3782};
3783var sortObj = {
3784 interval: 1,
3785 timeout: 1,
3786 TweenOneTicker: 2
3787};
3788var tickObjToArray = function tickObjToArray(obj) {
3789 return Object.keys(obj).map(function (k) {
3790 return {
3791 key: k,
3792 func: obj[k]
3793 };
3794 }).sort(function (a, b) {
3795 var aa = a.key.split('_')[0];
3796 var bb = b.key.split('_')[0];
3797 return sortObj[bb] - sortObj[aa];
3798 });
3799};
3800var Ticker = function Ticker() {};
3801Ticker.prototype = {
3802 tickFnArray: [],
3803 tickKeyObject: {},
3804 id: -1,
3805 tweenId: 0,
3806 frame: 0,
3807 perFrame: Math.round(1000 / 60),
3808 elapsed: 0,
3809 lastUpdate: getTime(),
3810 startTime: getTime(), // 开始时间,不计算 react 渲染时间;
3811 nextTime: 0,
3812 time: 0
3813};
3814var p = Ticker.prototype;
3815p.add = function (fn) {
3816 var key = 'TweenOneTicker_' + this.tweenId;
3817 this.tweenId++;
3818 this.wake(key, fn);
3819 return key;
3820};
3821p.wake = function (key, fn) {
3822 this.tickKeyObject[key] = fn;
3823 this.tickFnArray = tickObjToArray(this.tickKeyObject);
3824 if (this.id === -1) {
3825 this.id = __WEBPACK_IMPORTED_MODULE_0_raf___default()(this.tick);
3826 }
3827};
3828p.clear = function (key) {
3829 delete this.tickKeyObject[key];
3830 this.tickFnArray = tickObjToArray(this.tickKeyObject);
3831};
3832p.sleep = function () {
3833 __WEBPACK_IMPORTED_MODULE_0_raf___default.a.cancel(this.id);
3834 this.id = -1;
3835 this.frame = 0;
3836};
3837var ticker = new Ticker();
3838p.tick = function (a) {
3839 ticker.elapsed = getTime() - ticker.lastUpdate;
3840 // 离开当前时设值 300;大于 300 则为离开。
3841 if (ticker.elapsed > 300) {
3842 ticker.startTime += ticker.elapsed - ticker.perFrame;
3843 }
3844 ticker.lastUpdate += ticker.elapsed;
3845 ticker.time = ticker.lastUpdate - ticker.startTime;
3846 var overlap = ticker.time - ticker.nextTime;
3847 if (overlap > 0 || !ticker.frame) {
3848 ticker.frame++;
3849 ticker.nextTime += overlap;
3850 }
3851 // console.log(ticker.frame, ticker.nextTime, ticker.time)
3852 ticker.tickFnArray.forEach(function (item) {
3853 return item.func(a);
3854 });
3855 // 如果 object 里没对象了,自动杀掉;
3856 if (!ticker.tickFnArray.length) {
3857 ticker.sleep();
3858 return;
3859 }
3860 ticker.id = __WEBPACK_IMPORTED_MODULE_0_raf___default()(ticker.tick);
3861};
3862var timeoutIdNumber = 0;
3863p.timeout = function (fn, time) {
3864 var _this = this;
3865
3866 if (!(typeof fn === 'function')) {
3867 return console.warn('not function'); // eslint-disable-line
3868 }
3869 var timeoutID = 'timeout_' + Date.now() + '-' + timeoutIdNumber;
3870 var startTime = this.time;
3871 this.wake(timeoutID, function () {
3872 var moment = _this.time - startTime;
3873 if (moment >= (time || 0)) {
3874 _this.clear(timeoutID);
3875 fn();
3876 }
3877 });
3878 timeoutIdNumber++;
3879 return timeoutID;
3880};
3881var intervalIdNumber = 0;
3882p.interval = function (fn, time) {
3883 var _this2 = this;
3884
3885 if (!(typeof fn === 'function')) {
3886 console.warn('not function'); // eslint-disable-line
3887 return null;
3888 }
3889 var intervalID = 'interval_' + Date.now() + '-' + intervalIdNumber;
3890 var starTime = this.time;
3891 this.wake(intervalID, function () {
3892 var moment = _this2.time - starTime;
3893 if (moment >= (time || 0)) {
3894 starTime = _this2.time;
3895 fn();
3896 }
3897 });
3898 intervalIdNumber++;
3899 return intervalID;
3900};
3901/* harmony default export */ __webpack_exports__["a"] = (ticker);
3902
3903/***/ }),
3904/* 65 */
3905/***/ (function(module, __webpack_exports__, __webpack_require__) {
3906
3907"use strict";
3908/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__ = __webpack_require__(0);
3909/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__);
3910/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck__ = __webpack_require__(8);
3911/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck__);
3912/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_createClass__ = __webpack_require__(10);
3913/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_createClass___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_createClass__);
3914/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn__ = __webpack_require__(9);
3915/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn__);
3916/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits__ = __webpack_require__(11);
3917/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits__);
3918/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_react__ = __webpack_require__(1);
3919/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_react__);
3920/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_prop_types__ = __webpack_require__(5);
3921/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_prop_types__);
3922
3923
3924
3925
3926
3927
3928
3929
3930var Arrow = function (_Component) {
3931 __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits___default()(Arrow, _Component);
3932
3933 function Arrow() {
3934 var _ref;
3935
3936 var _temp, _this, _ret;
3937
3938 __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck___default()(this, Arrow);
3939
3940 for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
3941 args[_key] = arguments[_key];
3942 }
3943
3944 return _ret = (_temp = (_this = __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn___default()(this, (_ref = Arrow.__proto__ || Object.getPrototypeOf(Arrow)).call.apply(_ref, [this].concat(args))), _this), _this.onClick = function (e) {
3945 if (e.stopPropagation) {
3946 e.stopPropagation();
3947 }
3948 _this.props[_this.props.arrowType](e);
3949 }, _temp), __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn___default()(_this, _ret);
3950 }
3951
3952 __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_createClass___default()(Arrow, [{
3953 key: 'render',
3954 value: function render() {
3955 var className = this.props.className;
3956 var defaultClass = className + '-default';
3957 className = (className + ' ' + (this.props.prefixCls || '')).trim();
3958 className = !this.props['default'] ? className : (className + ' ' + defaultClass).trim();
3959 className = className + ' ' + this.props.arrowType;
3960 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, this.props, this.props.componentProps);
3961 ['arrowType', 'next', 'prev', 'component', 'componentProps', 'default', 'prefixCls'].forEach(function (key) {
3962 return delete props[key];
3963 });
3964 props.className = className;
3965 props.onClick = this.onClick;
3966 return __WEBPACK_IMPORTED_MODULE_5_react___default.a.createElement(this.props.component, props, this.props.children);
3967 }
3968 }]);
3969
3970 return Arrow;
3971}(__WEBPACK_IMPORTED_MODULE_5_react__["Component"]);
3972
3973Arrow.propTypes = {
3974 children: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
3975 style: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.object,
3976 className: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.string,
3977 prefixCls: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.string,
3978 component: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
3979 arrowType: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.string,
3980 'default': __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.bool,
3981 next: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.func,
3982 prev: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.func,
3983 componentProps: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.object
3984};
3985Arrow.defaultProps = {
3986 component: 'div',
3987 className: 'banner-anim-arrow',
3988 componentProps: {}
3989};
3990
3991Arrow.isBannerAnimArrow = true;
3992
3993/* harmony default export */ __webpack_exports__["a"] = (Arrow);
3994
3995/***/ }),
3996/* 66 */
3997/***/ (function(module, __webpack_exports__, __webpack_require__) {
3998
3999"use strict";
4000/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__ = __webpack_require__(0);
4001/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__);
4002/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck__ = __webpack_require__(8);
4003/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck__);
4004/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_createClass__ = __webpack_require__(10);
4005/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_createClass___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_createClass__);
4006/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn__ = __webpack_require__(9);
4007/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn__);
4008/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits__ = __webpack_require__(11);
4009/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits__);
4010/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_react__ = __webpack_require__(1);
4011/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_react__);
4012/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_prop_types__ = __webpack_require__(5);
4013/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_prop_types__);
4014/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__utils__ = __webpack_require__(18);
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024var Thumb = function (_Component) {
4025 __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits___default()(Thumb, _Component);
4026
4027 function Thumb() {
4028 var _ref;
4029
4030 var _temp, _this, _ret;
4031
4032 __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck___default()(this, Thumb);
4033
4034 for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
4035 args[_key] = arguments[_key];
4036 }
4037
4038 return _ret = (_temp = (_this = __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn___default()(this, (_ref = Thumb.__proto__ || Object.getPrototypeOf(Thumb)).call.apply(_ref, [this].concat(args))), _this), _this.getDefaultThumb = function () {
4039 var children = [];
4040 for (var i = 0; i < _this.props.length; i++) {
4041 children.push(__WEBPACK_IMPORTED_MODULE_5_react___default.a.createElement('span', { key: i }));
4042 }
4043 return children;
4044 }, _temp), __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn___default()(_this, _ret);
4045 }
4046
4047 __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_createClass___default()(Thumb, [{
4048 key: 'render',
4049 value: function render() {
4050 var _this2 = this;
4051
4052 var className = 'banner-anim-thumb';
4053 var defaultClass = className + '-default';
4054 className = (className + ' ' + (this.props.prefixCls || '')).trim();
4055 className = !this.props['default'] ? className : (className + ' ' + defaultClass).trim();
4056 var children = this.props['default'] ? this.getDefaultThumb() : this.props.children;
4057 if (this.props.length && Object(__WEBPACK_IMPORTED_MODULE_7__utils__["f" /* toArrayChildren */])(children).length !== this.props.length) {
4058 console.warn('The thumbnail length and the images length different.'); // eslint-disable-line
4059 }
4060 var childToRender = Object(__WEBPACK_IMPORTED_MODULE_7__utils__["f" /* toArrayChildren */])(children).map(function (item, i) {
4061 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, item.props);
4062 props.onClick = function (e) {
4063 if (e.stopPropagation) {
4064 e.stopPropagation();
4065 }
4066 _this2.props.thumbClick(i);
4067 };
4068 props.className = ((props.className || '') + ' ' + (_this2.props.active === i ? 'active' : '')).trim();
4069 return __WEBPACK_IMPORTED_MODULE_5_react___default.a.cloneElement(item, props);
4070 });
4071 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, this.props, this.props.componentProps);
4072 ['length', 'thumbClick', 'active', 'default', 'component', 'componentProps', 'prefixCls'].forEach(function (key) {
4073 return delete props[key];
4074 });
4075 props.className = className;
4076 return __WEBPACK_IMPORTED_MODULE_5_react___default.a.createElement(this.props.component, props, childToRender);
4077 }
4078 }]);
4079
4080 return Thumb;
4081}(__WEBPACK_IMPORTED_MODULE_5_react__["Component"]);
4082
4083Thumb.propTypes = {
4084 children: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
4085 style: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.object,
4086 prefixCls: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.string,
4087 component: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
4088 thumbClick: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.func,
4089 'default': __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.bool,
4090 length: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.number,
4091 active: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.number,
4092 componentProps: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.object
4093};
4094Thumb.defaultProps = {
4095 component: 'div',
4096 componentProps: {},
4097 thumbClick: function thumbClick() {}
4098};
4099Thumb.isBannerAnimThumb = true;
4100
4101/* harmony default export */ __webpack_exports__["a"] = (Thumb);
4102
4103/***/ }),
4104/* 67 */
4105/***/ (function(module, exports, __webpack_require__) {
4106
4107__webpack_require__(68);
4108module.exports = __webpack_require__(69);
4109
4110
4111/***/ }),
4112/* 68 */
4113/***/ (function(module, exports) {
4114
4115// removed by extract-text-webpack-plugin
4116
4117/***/ }),
4118/* 69 */
4119/***/ (function(module, __webpack_exports__, __webpack_require__) {
4120
4121"use strict";
4122Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
4123/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_react_lifecycles_compat__ = __webpack_require__(22);
4124/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__BannerAnim__ = __webpack_require__(70);
4125/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__Arrow__ = __webpack_require__(65);
4126/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__Element__ = __webpack_require__(122);
4127/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__Thumb__ = __webpack_require__(66);
4128/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__anim__ = __webpack_require__(30);
4129/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__utils__ = __webpack_require__(18);
4130/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Arrow", function() { return __WEBPACK_IMPORTED_MODULE_2__Arrow__["a"]; });
4131/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Element", function() { return __WEBPACK_IMPORTED_MODULE_3__Element__["a"]; });
4132/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Thumb", function() { return __WEBPACK_IMPORTED_MODULE_4__Thumb__["a"]; });
4133/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "animType", function() { return __WEBPACK_IMPORTED_MODULE_5__anim__["a"]; });
4134/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "setAnimCompToTagComp", function() { return __WEBPACK_IMPORTED_MODULE_6__utils__["d"]; });
4135/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "switchChildren", function() { return __WEBPACK_IMPORTED_MODULE_6__utils__["e"]; });
4136// export this package's api
4137
4138
4139
4140
4141
4142
4143
4144
4145__WEBPACK_IMPORTED_MODULE_1__BannerAnim__["a" /* default */].Arrow = __WEBPACK_IMPORTED_MODULE_2__Arrow__["a" /* default */];
4146__WEBPACK_IMPORTED_MODULE_1__BannerAnim__["a" /* default */].Element = __WEBPACK_IMPORTED_MODULE_3__Element__["a" /* default */];
4147__WEBPACK_IMPORTED_MODULE_1__BannerAnim__["a" /* default */].Thumb = __WEBPACK_IMPORTED_MODULE_4__Thumb__["a" /* default */];
4148__WEBPACK_IMPORTED_MODULE_1__BannerAnim__["a" /* default */].animType = __WEBPACK_IMPORTED_MODULE_5__anim__["a" /* default */];
4149__WEBPACK_IMPORTED_MODULE_1__BannerAnim__["a" /* default */].setAnimCompToTagComp = __WEBPACK_IMPORTED_MODULE_6__utils__["d" /* setAnimCompToTagComp */];
4150__WEBPACK_IMPORTED_MODULE_1__BannerAnim__["a" /* default */].switchChildren = __WEBPACK_IMPORTED_MODULE_6__utils__["e" /* switchChildren */];
4151
4152/* harmony default export */ __webpack_exports__["default"] = (Object(__WEBPACK_IMPORTED_MODULE_0_react_lifecycles_compat__["a" /* polyfill */])(__WEBPACK_IMPORTED_MODULE_1__BannerAnim__["a" /* default */]));
4153
4154
4155
4156/***/ }),
4157/* 70 */
4158/***/ (function(module, __webpack_exports__, __webpack_require__) {
4159
4160"use strict";
4161/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_objectWithoutProperties__ = __webpack_require__(47);
4162/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_objectWithoutProperties___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_objectWithoutProperties__);
4163/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_extends__ = __webpack_require__(0);
4164/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_extends___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_extends__);
4165/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_classCallCheck__ = __webpack_require__(8);
4166/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_classCallCheck___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_classCallCheck__);
4167/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn__ = __webpack_require__(9);
4168/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn__);
4169/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_createClass__ = __webpack_require__(10);
4170/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_createClass___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_createClass__);
4171/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_babel_runtime_helpers_inherits__ = __webpack_require__(11);
4172/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_babel_runtime_helpers_inherits___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_babel_runtime_helpers_inherits__);
4173/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_react__ = __webpack_require__(1);
4174/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_react__);
4175/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_react_dom__ = __webpack_require__(28);
4176/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_react_dom__);
4177/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_prop_types__ = __webpack_require__(5);
4178/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8_prop_types__);
4179/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_rc_tween_one__ = __webpack_require__(45);
4180/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__Arrow__ = __webpack_require__(65);
4181/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__Thumb__ = __webpack_require__(66);
4182/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__utils__ = __webpack_require__(18);
4183/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__anim__ = __webpack_require__(30);
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199var BannerAnim = function (_Component) {
4200 __WEBPACK_IMPORTED_MODULE_5_babel_runtime_helpers_inherits___default()(BannerAnim, _Component);
4201
4202 __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_createClass___default()(BannerAnim, null, [{
4203 key: 'getDerivedStateFromProps',
4204 value: function getDerivedStateFromProps(props, _ref) {
4205 var prevProps = _ref.prevProps,
4206 $self = _ref.$self;
4207
4208 var nextState = {
4209 prevProps: props
4210 };
4211 if (prevProps && props !== prevProps) {
4212 $self.tweenBool = false;
4213 }
4214 return nextState; // eslint-disable-line
4215 }
4216 }]);
4217
4218 function BannerAnim(props) {
4219 __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_classCallCheck___default()(this, BannerAnim);
4220
4221 var _this = __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn___default()(this, (BannerAnim.__proto__ || Object.getPrototypeOf(BannerAnim)).call(this, props));
4222
4223 _this.onMouseEnter = function (e) {
4224 _this.props.onMouseEnter(e);
4225 if (_this.props.autoPlay && _this.props.autoPlayEffect) {
4226 __WEBPACK_IMPORTED_MODULE_9_rc_tween_one__["c" /* ticker */].clear(_this.autoPlayId);
4227 _this.autoPlayId = -1;
4228 }
4229 };
4230
4231 _this.onMouseLeave = function (e) {
4232 _this.props.onMouseLeave(e);
4233 if (_this.props.autoPlay && _this.props.autoPlayEffect) {
4234 _this.autoPlay();
4235 }
4236 };
4237
4238 _this.onTouchStart = function (e) {
4239 if (e.touches && e.touches.length > 1 || _this.elemWrapper.length <= 1 || _this.getDomIsArrowOrThumb(e) || e.button === 2 || _this.tweenBool) {
4240 return;
4241 }
4242 if (_this.props.autoPlay) {
4243 __WEBPACK_IMPORTED_MODULE_9_rc_tween_one__["c" /* ticker */].clear(_this.autoPlayId);
4244 _this.autoPlayId = -1;
4245 }
4246 _this.animType = _this.getAnimType(_this.props.type);
4247 _this.currentShow = _this.state.currentShow;
4248 // this.mouseMoveType = 'start';
4249 _this.mouseStartXY = {
4250 startX: e.touches === undefined ? e.clientX : e.touches[0].clientX,
4251 startY: e.touches === undefined ? e.clientY : e.touches[0].clientY
4252 };
4253 };
4254
4255 _this.onTouchMove = function (e) {
4256 if (!_this.mouseStartXY || e.touches && e.touches.length > 1 || _this.tweenBool) {
4257 return;
4258 }
4259
4260 var _this$getDiffer = _this.getDiffer(e, e.touches),
4261 differ = _this$getDiffer.differ,
4262 rectName = _this$getDiffer.rectName;
4263
4264 if (!differ) {
4265 return;
4266 }
4267 var ratio = differ / _this.state.domRect[rectName] * 2;
4268 var ratioType = ratio < 0 ? '+' : '-';
4269 var currentShow = _this.currentShow;
4270 _this.mouseMoveType = 'update';
4271 if (_this.ratioType !== ratioType) {
4272 _this.ratioType = ratioType;
4273 _this.mouseMoveType = 'reChild';
4274 _this.setState({
4275 currentShow: currentShow
4276 });
4277 return;
4278 }
4279 if ((_this.animType === __WEBPACK_IMPORTED_MODULE_13__anim__["a" /* default */].gridBar || _this.animType === __WEBPACK_IMPORTED_MODULE_13__anim__["a" /* default */].grid) && e.touches) {
4280 return;
4281 }
4282 _this.ratio = ratio;
4283 if (_this.ratio) {
4284 var type = void 0;
4285 if (_this.ratio < 0) {
4286 currentShow += 1;
4287 type = 'next';
4288 } else {
4289 currentShow -= 1;
4290 type = 'prev';
4291 }
4292 _this.ratio = Math.abs(_this.ratio);
4293 _this.ratio = _this.ratio > 0.99 ? 0.99 : _this.ratio;
4294 currentShow = currentShow >= _this.elemWrapper.length ? 0 : currentShow;
4295 currentShow = currentShow < 0 ? _this.elemWrapper.length - 1 : currentShow;
4296 _this.setState({
4297 currentShow: currentShow,
4298 direction: type
4299 });
4300 }
4301 };
4302
4303 _this.onTouchEnd = function (e) {
4304 if (!_this.mouseStartXY || e.changedTouches && e.changedTouches.length > 1 || _this.tweenBool) {
4305 return;
4306 }
4307 if (_this.props.autoPlay && _this.autoPlayId === -1) {
4308 _this.autoPlay();
4309 }
4310
4311 var _this$getDiffer2 = _this.getDiffer(e, e.changedTouches),
4312 differ = _this$getDiffer2.differ,
4313 rectName = _this$getDiffer2.rectName;
4314
4315 delete _this.mouseStartXY;
4316 _this.mouseMoveType = 'end';
4317 if (!differ) {
4318 _this.mouseMoveType = '';
4319 return;
4320 }
4321 if ((_this.animType === __WEBPACK_IMPORTED_MODULE_13__anim__["a" /* default */].gridBar || _this.animType === __WEBPACK_IMPORTED_MODULE_13__anim__["a" /* default */].grid) && e.changedTouches) {
4322 var currentShow = _this.currentShow;
4323 var ratio = differ / _this.state.domRect[rectName] * 2;
4324 if (ratio < 0) {
4325 currentShow += 1;
4326 } else {
4327 currentShow -= 1;
4328 }
4329 currentShow = currentShow >= _this.elemWrapper.length ? 0 : currentShow;
4330 currentShow = currentShow < 0 ? _this.elemWrapper.length - 1 : currentShow;
4331 _this.ratio = 0;
4332 _this.mouseMoveType = '';
4333 _this.slickGoTo(currentShow, true);
4334 _this.tweenBool = true;
4335 return;
4336 }
4337
4338 if (_this.ratio > 0.3) {
4339 _this.forceUpdate(function () {
4340 _this.ratio = 0;
4341 _this.mouseMoveType = '';
4342 });
4343 } else {
4344 _this.setState({
4345 currentShow: _this.currentShow,
4346 direction: _this.ratioType === '+' ? 'prev' : 'next'
4347 }, function () {
4348 _this.ratio = 0;
4349 _this.mouseMoveType = '';
4350 });
4351 }
4352 };
4353
4354 _this.getDiffer = function (e, touches) {
4355 var currentX = touches === undefined ? e.clientX : touches[0].clientX;
4356 var currentY = touches === undefined ? e.clientY : touches[0].clientY;
4357 var differX = currentX - _this.mouseStartXY.startX;
4358 var differY = currentY - _this.mouseStartXY.startY;
4359 var differ = Math.max(Math.abs(differX), Math.abs(differY));
4360 differ = differ === Math.abs(differX) ? differX : differY;
4361 return {
4362 differ: differ,
4363 rectName: differ === differX ? 'width' : 'height'
4364 };
4365 };
4366
4367 _this.getDomIsArrowOrThumb = function (e) {
4368 var arrowClassName = e.target.className;
4369 var thumbClassName = e.target.parentNode.className;
4370 if (arrowClassName.indexOf('banner-anim-arrow') >= 0 || thumbClassName.indexOf('banner-anim-thumb') >= 0) {
4371 return true;
4372 }
4373 return false;
4374 };
4375
4376 _this.getRenderChildren = function (children) {
4377 var elem = [];
4378 var arrow = [];
4379 var thumb = void 0;
4380 var elementKeyNum = 0;
4381 var thumbKeyNum = 0;
4382
4383 Object(__WEBPACK_IMPORTED_MODULE_12__utils__["f" /* toArrayChildren */])(children).forEach(function (item, i) {
4384 if (!item) {
4385 return;
4386 }
4387 var itemProps = __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_extends___default()({}, item.props);
4388 if (item.type.isBannerAnimElement) {
4389 itemProps.key = item.key || 'element-' + elementKeyNum;
4390 elementKeyNum += 1;
4391 itemProps.callBack = _this.animEnd;
4392 itemProps.show = _this.state.currentShow === i;
4393 itemProps.animType = _this.animType;
4394 itemProps.duration = _this.props.duration;
4395 itemProps.delay = _this.props.delay;
4396 itemProps.ease = _this.props.ease;
4397 itemProps.sync = _this.props.sync || itemProps.sync;
4398 itemProps.elemOffset = {
4399 top: _this.state.domRect.top,
4400 width: _this.state.domRect.width,
4401 height: _this.state.domRect.height
4402 };
4403 itemProps.direction = _this.state.direction;
4404 itemProps.ratio = _this.ratio;
4405 itemProps.mouseMoveType = _this.mouseMoveType;
4406 elem.push(__WEBPACK_IMPORTED_MODULE_6_react___default.a.cloneElement(item, itemProps));
4407 } else if (item.type.isBannerAnimArrow) {
4408 itemProps.next = _this.next;
4409 itemProps.prev = _this.prev;
4410 itemProps.key = item.key || itemProps.arrowType;
4411 itemProps.elemHeight = _this.state.domRect.height;
4412 arrow.push(__WEBPACK_IMPORTED_MODULE_6_react___default.a.cloneElement(item, itemProps));
4413 } else if (item.type.isBannerAnimThumb) {
4414 itemProps.key = item.key || 'thumb-' + thumbKeyNum;
4415 thumbKeyNum += 1;
4416 itemProps.thumbClick = _this.slickGoTo;
4417 itemProps.active = _this.state.currentShow;
4418 thumb = __WEBPACK_IMPORTED_MODULE_6_react___default.a.cloneElement(item, itemProps);
4419 }
4420 });
4421 if (elem.length > 1) {
4422 if (!arrow.length && _this.props.arrow) {
4423 arrow.push(__WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_10__Arrow__["a" /* default */], { arrowType: 'prev', key: 'arrowPrev', next: _this.next, prev: _this.prev, 'default': true }), __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_10__Arrow__["a" /* default */], { arrowType: 'next', key: 'arrowNext', next: _this.next, prev: _this.prev, 'default': true }));
4424 }
4425 if (!thumb && _this.props.thumb) {
4426 thumb = __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_11__Thumb__["a" /* default */], { length: elem.length, key: 'thumb',
4427 thumbClick: _this.slickGoTo,
4428 active: _this.state.currentShow,
4429 'default': true
4430 });
4431 }
4432 }
4433 _this.elemWrapper = elem;
4434 return elem.concat(arrow, thumb);
4435 };
4436
4437 _this.getDomDataSetToState = function () {
4438 _this.dom = __WEBPACK_IMPORTED_MODULE_7_react_dom___default.a.findDOMNode(_this);
4439 var domRect = _this.dom.getBoundingClientRect();
4440 _this.setState({
4441 domRect: domRect
4442 });
4443 _this.tweenBool = false;
4444 };
4445
4446 _this.getAnimType = function (type) {
4447 var typeArray = type ? Object(__WEBPACK_IMPORTED_MODULE_12__utils__["c" /* dataToArray */])(type) : Object.keys(__WEBPACK_IMPORTED_MODULE_13__anim__["a" /* default */]);
4448 var random = Math.round(Math.random() * (typeArray.length - 1));
4449 return __WEBPACK_IMPORTED_MODULE_13__anim__["a" /* default */][typeArray[random]];
4450 };
4451
4452 _this.autoPlay = function () {
4453 _this.autoPlayId = __WEBPACK_IMPORTED_MODULE_9_rc_tween_one__["c" /* ticker */].interval(_this.next, _this.props.autoPlaySpeed);
4454 };
4455
4456 _this.animTweenStart = function (show, type, noGetAnimType) {
4457 if (!noGetAnimType) {
4458 _this.animType = _this.getAnimType(_this.props.type);
4459 }
4460 _this.props.onChange('before', show);
4461 _this.setState({
4462 currentShow: show,
4463 direction: type
4464 });
4465 };
4466
4467 _this.animEnd = function (type) {
4468 if (type === 'enter') {
4469 _this.tweenBool = false;
4470 _this.props.onChange('after', _this.state.currentShow);
4471 }
4472 };
4473
4474 _this.next = function () {
4475 if (!_this.tweenBool) {
4476 _this.tweenBool = true;
4477 var newShow = _this.state.currentShow;
4478 newShow++;
4479 if (newShow >= _this.elemWrapper.length) {
4480 newShow = 0;
4481 }
4482 _this.animTweenStart(newShow, 'next');
4483 }
4484 };
4485
4486 _this.prev = function () {
4487 if (!_this.tweenBool) {
4488 _this.tweenBool = true;
4489 var newShow = _this.state.currentShow;
4490 newShow--;
4491 if (newShow < 0) {
4492 newShow = _this.elemWrapper.length - 1;
4493 }
4494 _this.animTweenStart(newShow, 'prev');
4495 }
4496 };
4497
4498 _this.slickGoTo = function (i, noGetAnimType) {
4499 if (!_this.tweenBool && i !== _this.state.currentShow) {
4500 _this.tweenBool = true;
4501 var type = i > _this.state.currentShow ? 'next' : 'prev';
4502 _this.animTweenStart(i, type, noGetAnimType);
4503 }
4504 };
4505
4506 _this.state = {
4507 currentShow: _this.props.initShow,
4508 direction: null,
4509 domRect: {},
4510 $self: _this // eslint-disable-line
4511 };
4512 _this.tweenBool = false;
4513 return _this;
4514 }
4515
4516 __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_createClass___default()(BannerAnim, [{
4517 key: 'componentDidMount',
4518 value: function componentDidMount() {
4519 this.getDomDataSetToState();
4520 if (window.addEventListener) {
4521 window.addEventListener('resize', this.getDomDataSetToState);
4522 } else {
4523 window.attachEvent('onresize', this.getDomDataSetToState);
4524 }
4525 if (this.props.autoPlay) {
4526 this.autoPlay();
4527 }
4528 }
4529 }, {
4530 key: 'componentWillUnmount',
4531 value: function componentWillUnmount() {
4532 if (this.autoPlayId) {
4533 __WEBPACK_IMPORTED_MODULE_9_rc_tween_one__["c" /* ticker */].clear(this.autoPlayId);
4534 this.autoPlayId = 0;
4535 }
4536 if (window.addEventListener) {
4537 window.removeEventListener('touchend', this.onTouchEnd);
4538 window.removeEventListener('mouseup', this.onTouchEnd);
4539 window.removeEventListener('resize', this.getDomDataSetToState);
4540 } else {
4541 window.detachEvent('ontouchend', this.onTouchEnd);
4542 window.attachEvent('onmouseup', this.onTouchEnd);
4543 window.detachEvent('onresize', this.getDomDataSetToState);
4544 }
4545 }
4546 }, {
4547 key: 'render',
4548 value: function render() {
4549 var _props = this.props,
4550 type = _props.type,
4551 prefixCls = _props.prefixCls,
4552 component = _props.component,
4553 initShow = _props.initShow,
4554 duration = _props.duration,
4555 delay = _props.delay,
4556 ease = _props.ease,
4557 arrow = _props.arrow,
4558 thumb = _props.thumb,
4559 autoPlaySpeed = _props.autoPlaySpeed,
4560 autoPlay = _props.autoPlay,
4561 sync = _props.sync,
4562 dragPlay = _props.dragPlay,
4563 autoPlayEffect = _props.autoPlayEffect,
4564 props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_objectWithoutProperties___default()(_props, ['type', 'prefixCls', 'component', 'initShow', 'duration', 'delay', 'ease', 'arrow', 'thumb', 'autoPlaySpeed', 'autoPlay', 'sync', 'dragPlay', 'autoPlayEffect']);
4565
4566 var childrenToRender = this.getRenderChildren(props.children);
4567 props.className = (props.className + ' ' + (prefixCls || '')).trim();
4568 props.style = __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_extends___default()({}, props.style);
4569 props.onMouseEnter = this.onMouseEnter;
4570 props.onMouseLeave = this.onMouseLeave;
4571 if (childrenToRender.length > 1 && this.props.dragPlay) {
4572 props.onTouchStart = this.onTouchStart;
4573 props.onMouseDown = this.onTouchStart;
4574 props.onTouchMove = this.onTouchMove;
4575 props.onMouseMove = this.onTouchMove;
4576 props.onTouchEnd = this.onTouchEnd;
4577 props.onMouseUp = this.onTouchEnd;
4578 }
4579 return __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(this.props.component, props, childrenToRender);
4580 }
4581 }]);
4582
4583 return BannerAnim;
4584}(__WEBPACK_IMPORTED_MODULE_6_react__["Component"]);
4585
4586BannerAnim.propTypes = {
4587 children: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.any,
4588 style: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.object,
4589 className: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.string,
4590 prefixCls: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.string,
4591 component: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.any,
4592 arrow: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.bool,
4593 thumb: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.bool,
4594 initShow: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.number,
4595 type: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.any,
4596 duration: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.number,
4597 delay: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.number,
4598 ease: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.string,
4599 autoPlay: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.bool,
4600 autoPlaySpeed: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.number,
4601 autoPlayEffect: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.bool,
4602 onChange: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.func,
4603 onMouseEnter: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.func,
4604 onMouseLeave: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.func,
4605 sync: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.bool,
4606 dragPlay: __WEBPACK_IMPORTED_MODULE_8_prop_types___default.a.bool
4607};
4608BannerAnim.defaultProps = {
4609 component: 'div',
4610 className: 'banner-anim',
4611 initShow: 0,
4612 duration: 450,
4613 delay: 0,
4614 ease: 'easeInOutQuad',
4615 arrow: true,
4616 thumb: true,
4617 autoPlaySpeed: 5000,
4618 autoPlayEffect: true,
4619 dragPlay: true,
4620 onChange: function onChange() {},
4621 onMouseEnter: function onMouseEnter() {},
4622 onMouseLeave: function onMouseLeave() {}
4623};
4624BannerAnim.isBannerAnim = true;
4625/* harmony default export */ __webpack_exports__["a"] = (BannerAnim);
4626
4627/***/ }),
4628/* 71 */
4629/***/ (function(module, exports, __webpack_require__) {
4630
4631module.exports = { "default": __webpack_require__(72), __esModule: true };
4632
4633/***/ }),
4634/* 72 */
4635/***/ (function(module, exports, __webpack_require__) {
4636
4637__webpack_require__(73);
4638module.exports = __webpack_require__(3).Object.assign;
4639
4640
4641/***/ }),
4642/* 73 */
4643/***/ (function(module, exports, __webpack_require__) {
4644
4645// 19.1.3.1 Object.assign(target, source)
4646var $export = __webpack_require__(12);
4647
4648$export($export.S + $export.F, 'Object', { assign: __webpack_require__(75) });
4649
4650
4651/***/ }),
4652/* 74 */
4653/***/ (function(module, exports) {
4654
4655module.exports = function (it) {
4656 if (typeof it != 'function') throw TypeError(it + ' is not a function!');
4657 return it;
4658};
4659
4660
4661/***/ }),
4662/* 75 */
4663/***/ (function(module, exports, __webpack_require__) {
4664
4665"use strict";
4666
4667// 19.1.2.1 Object.assign(target, source, ...)
4668var DESCRIPTORS = __webpack_require__(4);
4669var getKeys = __webpack_require__(24);
4670var gOPS = __webpack_require__(37);
4671var pIE = __webpack_require__(27);
4672var toObject = __webpack_require__(38);
4673var IObject = __webpack_require__(52);
4674var $assign = Object.assign;
4675
4676// should work with symbols and should have deterministic property order (V8 bug)
4677module.exports = !$assign || __webpack_require__(20)(function () {
4678 var A = {};
4679 var B = {};
4680 // eslint-disable-next-line no-undef
4681 var S = Symbol();
4682 var K = 'abcdefghijklmnopqrst';
4683 A[S] = 7;
4684 K.split('').forEach(function (k) { B[k] = k; });
4685 return $assign({}, A)[S] != 7 || Object.keys($assign({}, B)).join('') != K;
4686}) ? function assign(target, source) { // eslint-disable-line no-unused-vars
4687 var T = toObject(target);
4688 var aLen = arguments.length;
4689 var index = 1;
4690 var getSymbols = gOPS.f;
4691 var isEnum = pIE.f;
4692 while (aLen > index) {
4693 var S = IObject(arguments[index++]);
4694 var keys = getSymbols ? getKeys(S).concat(getSymbols(S)) : getKeys(S);
4695 var length = keys.length;
4696 var j = 0;
4697 var key;
4698 while (length > j) {
4699 key = keys[j++];
4700 if (!DESCRIPTORS || isEnum.call(S, key)) T[key] = S[key];
4701 }
4702 } return T;
4703} : $assign;
4704
4705
4706/***/ }),
4707/* 76 */
4708/***/ (function(module, exports, __webpack_require__) {
4709
4710// false -> Array#indexOf
4711// true -> Array#includes
4712var toIObject = __webpack_require__(15);
4713var toLength = __webpack_require__(77);
4714var toAbsoluteIndex = __webpack_require__(78);
4715module.exports = function (IS_INCLUDES) {
4716 return function ($this, el, fromIndex) {
4717 var O = toIObject($this);
4718 var length = toLength(O.length);
4719 var index = toAbsoluteIndex(fromIndex, length);
4720 var value;
4721 // Array#includes uses SameValueZero equality algorithm
4722 // eslint-disable-next-line no-self-compare
4723 if (IS_INCLUDES && el != el) while (length > index) {
4724 value = O[index++];
4725 // eslint-disable-next-line no-self-compare
4726 if (value != value) return true;
4727 // Array#indexOf ignores holes, Array#includes - not
4728 } else for (;length > index; index++) if (IS_INCLUDES || index in O) {
4729 if (O[index] === el) return IS_INCLUDES || index || 0;
4730 } return !IS_INCLUDES && -1;
4731 };
4732};
4733
4734
4735/***/ }),
4736/* 77 */
4737/***/ (function(module, exports, __webpack_require__) {
4738
4739// 7.1.15 ToLength
4740var toInteger = __webpack_require__(33);
4741var min = Math.min;
4742module.exports = function (it) {
4743 return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991
4744};
4745
4746
4747/***/ }),
4748/* 78 */
4749/***/ (function(module, exports, __webpack_require__) {
4750
4751var toInteger = __webpack_require__(33);
4752var max = Math.max;
4753var min = Math.min;
4754module.exports = function (index, length) {
4755 index = toInteger(index);
4756 return index < 0 ? max(index + length, 0) : min(index, length);
4757};
4758
4759
4760/***/ }),
4761/* 79 */
4762/***/ (function(module, exports, __webpack_require__) {
4763
4764module.exports = { "default": __webpack_require__(80), __esModule: true };
4765
4766/***/ }),
4767/* 80 */
4768/***/ (function(module, exports, __webpack_require__) {
4769
4770__webpack_require__(81);
4771__webpack_require__(87);
4772module.exports = __webpack_require__(42).f('iterator');
4773
4774
4775/***/ }),
4776/* 81 */
4777/***/ (function(module, exports, __webpack_require__) {
4778
4779"use strict";
4780
4781var $at = __webpack_require__(82)(true);
4782
4783// 21.1.3.27 String.prototype[@@iterator]()
4784__webpack_require__(55)(String, 'String', function (iterated) {
4785 this._t = String(iterated); // target
4786 this._i = 0; // next index
4787// 21.1.5.2.1 %StringIteratorPrototype%.next()
4788}, function () {
4789 var O = this._t;
4790 var index = this._i;
4791 var point;
4792 if (index >= O.length) return { value: undefined, done: true };
4793 point = $at(O, index);
4794 this._i += point.length;
4795 return { value: point, done: false };
4796});
4797
4798
4799/***/ }),
4800/* 82 */
4801/***/ (function(module, exports, __webpack_require__) {
4802
4803var toInteger = __webpack_require__(33);
4804var defined = __webpack_require__(32);
4805// true -> String#at
4806// false -> String#codePointAt
4807module.exports = function (TO_STRING) {
4808 return function (that, pos) {
4809 var s = String(defined(that));
4810 var i = toInteger(pos);
4811 var l = s.length;
4812 var a, b;
4813 if (i < 0 || i >= l) return TO_STRING ? '' : undefined;
4814 a = s.charCodeAt(i);
4815 return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff
4816 ? TO_STRING ? s.charAt(i) : a
4817 : TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;
4818 };
4819};
4820
4821
4822/***/ }),
4823/* 83 */
4824/***/ (function(module, exports, __webpack_require__) {
4825
4826"use strict";
4827
4828var create = __webpack_require__(40);
4829var descriptor = __webpack_require__(23);
4830var setToStringTag = __webpack_require__(41);
4831var IteratorPrototype = {};
4832
4833// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()
4834__webpack_require__(13)(IteratorPrototype, __webpack_require__(16)('iterator'), function () { return this; });
4835
4836module.exports = function (Constructor, NAME, next) {
4837 Constructor.prototype = create(IteratorPrototype, { next: descriptor(1, next) });
4838 setToStringTag(Constructor, NAME + ' Iterator');
4839};
4840
4841
4842/***/ }),
4843/* 84 */
4844/***/ (function(module, exports, __webpack_require__) {
4845
4846var dP = __webpack_require__(6);
4847var anObject = __webpack_require__(19);
4848var getKeys = __webpack_require__(24);
4849
4850module.exports = __webpack_require__(4) ? Object.defineProperties : function defineProperties(O, Properties) {
4851 anObject(O);
4852 var keys = getKeys(Properties);
4853 var length = keys.length;
4854 var i = 0;
4855 var P;
4856 while (length > i) dP.f(O, P = keys[i++], Properties[P]);
4857 return O;
4858};
4859
4860
4861/***/ }),
4862/* 85 */
4863/***/ (function(module, exports, __webpack_require__) {
4864
4865var document = __webpack_require__(2).document;
4866module.exports = document && document.documentElement;
4867
4868
4869/***/ }),
4870/* 86 */
4871/***/ (function(module, exports, __webpack_require__) {
4872
4873// 19.1.2.9 / 15.2.3.2 Object.getPrototypeOf(O)
4874var has = __webpack_require__(7);
4875var toObject = __webpack_require__(38);
4876var IE_PROTO = __webpack_require__(34)('IE_PROTO');
4877var ObjectProto = Object.prototype;
4878
4879module.exports = Object.getPrototypeOf || function (O) {
4880 O = toObject(O);
4881 if (has(O, IE_PROTO)) return O[IE_PROTO];
4882 if (typeof O.constructor == 'function' && O instanceof O.constructor) {
4883 return O.constructor.prototype;
4884 } return O instanceof Object ? ObjectProto : null;
4885};
4886
4887
4888/***/ }),
4889/* 87 */
4890/***/ (function(module, exports, __webpack_require__) {
4891
4892__webpack_require__(88);
4893var global = __webpack_require__(2);
4894var hide = __webpack_require__(13);
4895var Iterators = __webpack_require__(39);
4896var TO_STRING_TAG = __webpack_require__(16)('toStringTag');
4897
4898var DOMIterables = ('CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,' +
4899 'DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,' +
4900 'MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,' +
4901 'SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,' +
4902 'TextTrackList,TouchList').split(',');
4903
4904for (var i = 0; i < DOMIterables.length; i++) {
4905 var NAME = DOMIterables[i];
4906 var Collection = global[NAME];
4907 var proto = Collection && Collection.prototype;
4908 if (proto && !proto[TO_STRING_TAG]) hide(proto, TO_STRING_TAG, NAME);
4909 Iterators[NAME] = Iterators.Array;
4910}
4911
4912
4913/***/ }),
4914/* 88 */
4915/***/ (function(module, exports, __webpack_require__) {
4916
4917"use strict";
4918
4919var addToUnscopables = __webpack_require__(89);
4920var step = __webpack_require__(90);
4921var Iterators = __webpack_require__(39);
4922var toIObject = __webpack_require__(15);
4923
4924// 22.1.3.4 Array.prototype.entries()
4925// 22.1.3.13 Array.prototype.keys()
4926// 22.1.3.29 Array.prototype.values()
4927// 22.1.3.30 Array.prototype[@@iterator]()
4928module.exports = __webpack_require__(55)(Array, 'Array', function (iterated, kind) {
4929 this._t = toIObject(iterated); // target
4930 this._i = 0; // next index
4931 this._k = kind; // kind
4932// 22.1.5.2.1 %ArrayIteratorPrototype%.next()
4933}, function () {
4934 var O = this._t;
4935 var kind = this._k;
4936 var index = this._i++;
4937 if (!O || index >= O.length) {
4938 this._t = undefined;
4939 return step(1);
4940 }
4941 if (kind == 'keys') return step(0, index);
4942 if (kind == 'values') return step(0, O[index]);
4943 return step(0, [index, O[index]]);
4944}, 'values');
4945
4946// argumentsList[@@iterator] is %ArrayProto_values% (9.4.4.6, 9.4.4.7)
4947Iterators.Arguments = Iterators.Array;
4948
4949addToUnscopables('keys');
4950addToUnscopables('values');
4951addToUnscopables('entries');
4952
4953
4954/***/ }),
4955/* 89 */
4956/***/ (function(module, exports) {
4957
4958module.exports = function () { /* empty */ };
4959
4960
4961/***/ }),
4962/* 90 */
4963/***/ (function(module, exports) {
4964
4965module.exports = function (done, value) {
4966 return { value: value, done: !!done };
4967};
4968
4969
4970/***/ }),
4971/* 91 */
4972/***/ (function(module, exports, __webpack_require__) {
4973
4974module.exports = { "default": __webpack_require__(92), __esModule: true };
4975
4976/***/ }),
4977/* 92 */
4978/***/ (function(module, exports, __webpack_require__) {
4979
4980__webpack_require__(93);
4981__webpack_require__(98);
4982__webpack_require__(99);
4983__webpack_require__(100);
4984module.exports = __webpack_require__(3).Symbol;
4985
4986
4987/***/ }),
4988/* 93 */
4989/***/ (function(module, exports, __webpack_require__) {
4990
4991"use strict";
4992
4993// ECMAScript 6 symbols shim
4994var global = __webpack_require__(2);
4995var has = __webpack_require__(7);
4996var DESCRIPTORS = __webpack_require__(4);
4997var $export = __webpack_require__(12);
4998var redefine = __webpack_require__(56);
4999var META = __webpack_require__(94).KEY;
5000var $fails = __webpack_require__(20);
5001var shared = __webpack_require__(35);
5002var setToStringTag = __webpack_require__(41);
5003var uid = __webpack_require__(26);
5004var wks = __webpack_require__(16);
5005var wksExt = __webpack_require__(42);
5006var wksDefine = __webpack_require__(43);
5007var enumKeys = __webpack_require__(95);
5008var isArray = __webpack_require__(96);
5009var anObject = __webpack_require__(19);
5010var isObject = __webpack_require__(14);
5011var toObject = __webpack_require__(38);
5012var toIObject = __webpack_require__(15);
5013var toPrimitive = __webpack_require__(31);
5014var createDesc = __webpack_require__(23);
5015var _create = __webpack_require__(40);
5016var gOPNExt = __webpack_require__(97);
5017var $GOPD = __webpack_require__(58);
5018var $GOPS = __webpack_require__(37);
5019var $DP = __webpack_require__(6);
5020var $keys = __webpack_require__(24);
5021var gOPD = $GOPD.f;
5022var dP = $DP.f;
5023var gOPN = gOPNExt.f;
5024var $Symbol = global.Symbol;
5025var $JSON = global.JSON;
5026var _stringify = $JSON && $JSON.stringify;
5027var PROTOTYPE = 'prototype';
5028var HIDDEN = wks('_hidden');
5029var TO_PRIMITIVE = wks('toPrimitive');
5030var isEnum = {}.propertyIsEnumerable;
5031var SymbolRegistry = shared('symbol-registry');
5032var AllSymbols = shared('symbols');
5033var OPSymbols = shared('op-symbols');
5034var ObjectProto = Object[PROTOTYPE];
5035var USE_NATIVE = typeof $Symbol == 'function' && !!$GOPS.f;
5036var QObject = global.QObject;
5037// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173
5038var setter = !QObject || !QObject[PROTOTYPE] || !QObject[PROTOTYPE].findChild;
5039
5040// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687
5041var setSymbolDesc = DESCRIPTORS && $fails(function () {
5042 return _create(dP({}, 'a', {
5043 get: function () { return dP(this, 'a', { value: 7 }).a; }
5044 })).a != 7;
5045}) ? function (it, key, D) {
5046 var protoDesc = gOPD(ObjectProto, key);
5047 if (protoDesc) delete ObjectProto[key];
5048 dP(it, key, D);
5049 if (protoDesc && it !== ObjectProto) dP(ObjectProto, key, protoDesc);
5050} : dP;
5051
5052var wrap = function (tag) {
5053 var sym = AllSymbols[tag] = _create($Symbol[PROTOTYPE]);
5054 sym._k = tag;
5055 return sym;
5056};
5057
5058var isSymbol = USE_NATIVE && typeof $Symbol.iterator == 'symbol' ? function (it) {
5059 return typeof it == 'symbol';
5060} : function (it) {
5061 return it instanceof $Symbol;
5062};
5063
5064var $defineProperty = function defineProperty(it, key, D) {
5065 if (it === ObjectProto) $defineProperty(OPSymbols, key, D);
5066 anObject(it);
5067 key = toPrimitive(key, true);
5068 anObject(D);
5069 if (has(AllSymbols, key)) {
5070 if (!D.enumerable) {
5071 if (!has(it, HIDDEN)) dP(it, HIDDEN, createDesc(1, {}));
5072 it[HIDDEN][key] = true;
5073 } else {
5074 if (has(it, HIDDEN) && it[HIDDEN][key]) it[HIDDEN][key] = false;
5075 D = _create(D, { enumerable: createDesc(0, false) });
5076 } return setSymbolDesc(it, key, D);
5077 } return dP(it, key, D);
5078};
5079var $defineProperties = function defineProperties(it, P) {
5080 anObject(it);
5081 var keys = enumKeys(P = toIObject(P));
5082 var i = 0;
5083 var l = keys.length;
5084 var key;
5085 while (l > i) $defineProperty(it, key = keys[i++], P[key]);
5086 return it;
5087};
5088var $create = function create(it, P) {
5089 return P === undefined ? _create(it) : $defineProperties(_create(it), P);
5090};
5091var $propertyIsEnumerable = function propertyIsEnumerable(key) {
5092 var E = isEnum.call(this, key = toPrimitive(key, true));
5093 if (this === ObjectProto && has(AllSymbols, key) && !has(OPSymbols, key)) return false;
5094 return E || !has(this, key) || !has(AllSymbols, key) || has(this, HIDDEN) && this[HIDDEN][key] ? E : true;
5095};
5096var $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(it, key) {
5097 it = toIObject(it);
5098 key = toPrimitive(key, true);
5099 if (it === ObjectProto && has(AllSymbols, key) && !has(OPSymbols, key)) return;
5100 var D = gOPD(it, key);
5101 if (D && has(AllSymbols, key) && !(has(it, HIDDEN) && it[HIDDEN][key])) D.enumerable = true;
5102 return D;
5103};
5104var $getOwnPropertyNames = function getOwnPropertyNames(it) {
5105 var names = gOPN(toIObject(it));
5106 var result = [];
5107 var i = 0;
5108 var key;
5109 while (names.length > i) {
5110 if (!has(AllSymbols, key = names[i++]) && key != HIDDEN && key != META) result.push(key);
5111 } return result;
5112};
5113var $getOwnPropertySymbols = function getOwnPropertySymbols(it) {
5114 var IS_OP = it === ObjectProto;
5115 var names = gOPN(IS_OP ? OPSymbols : toIObject(it));
5116 var result = [];
5117 var i = 0;
5118 var key;
5119 while (names.length > i) {
5120 if (has(AllSymbols, key = names[i++]) && (IS_OP ? has(ObjectProto, key) : true)) result.push(AllSymbols[key]);
5121 } return result;
5122};
5123
5124// 19.4.1.1 Symbol([description])
5125if (!USE_NATIVE) {
5126 $Symbol = function Symbol() {
5127 if (this instanceof $Symbol) throw TypeError('Symbol is not a constructor!');
5128 var tag = uid(arguments.length > 0 ? arguments[0] : undefined);
5129 var $set = function (value) {
5130 if (this === ObjectProto) $set.call(OPSymbols, value);
5131 if (has(this, HIDDEN) && has(this[HIDDEN], tag)) this[HIDDEN][tag] = false;
5132 setSymbolDesc(this, tag, createDesc(1, value));
5133 };
5134 if (DESCRIPTORS && setter) setSymbolDesc(ObjectProto, tag, { configurable: true, set: $set });
5135 return wrap(tag);
5136 };
5137 redefine($Symbol[PROTOTYPE], 'toString', function toString() {
5138 return this._k;
5139 });
5140
5141 $GOPD.f = $getOwnPropertyDescriptor;
5142 $DP.f = $defineProperty;
5143 __webpack_require__(57).f = gOPNExt.f = $getOwnPropertyNames;
5144 __webpack_require__(27).f = $propertyIsEnumerable;
5145 $GOPS.f = $getOwnPropertySymbols;
5146
5147 if (DESCRIPTORS && !__webpack_require__(25)) {
5148 redefine(ObjectProto, 'propertyIsEnumerable', $propertyIsEnumerable, true);
5149 }
5150
5151 wksExt.f = function (name) {
5152 return wrap(wks(name));
5153 };
5154}
5155
5156$export($export.G + $export.W + $export.F * !USE_NATIVE, { Symbol: $Symbol });
5157
5158for (var es6Symbols = (
5159 // 19.4.2.2, 19.4.2.3, 19.4.2.4, 19.4.2.6, 19.4.2.8, 19.4.2.9, 19.4.2.10, 19.4.2.11, 19.4.2.12, 19.4.2.13, 19.4.2.14
5160 'hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables'
5161).split(','), j = 0; es6Symbols.length > j;)wks(es6Symbols[j++]);
5162
5163for (var wellKnownSymbols = $keys(wks.store), k = 0; wellKnownSymbols.length > k;) wksDefine(wellKnownSymbols[k++]);
5164
5165$export($export.S + $export.F * !USE_NATIVE, 'Symbol', {
5166 // 19.4.2.1 Symbol.for(key)
5167 'for': function (key) {
5168 return has(SymbolRegistry, key += '')
5169 ? SymbolRegistry[key]
5170 : SymbolRegistry[key] = $Symbol(key);
5171 },
5172 // 19.4.2.5 Symbol.keyFor(sym)
5173 keyFor: function keyFor(sym) {
5174 if (!isSymbol(sym)) throw TypeError(sym + ' is not a symbol!');
5175 for (var key in SymbolRegistry) if (SymbolRegistry[key] === sym) return key;
5176 },
5177 useSetter: function () { setter = true; },
5178 useSimple: function () { setter = false; }
5179});
5180
5181$export($export.S + $export.F * !USE_NATIVE, 'Object', {
5182 // 19.1.2.2 Object.create(O [, Properties])
5183 create: $create,
5184 // 19.1.2.4 Object.defineProperty(O, P, Attributes)
5185 defineProperty: $defineProperty,
5186 // 19.1.2.3 Object.defineProperties(O, Properties)
5187 defineProperties: $defineProperties,
5188 // 19.1.2.6 Object.getOwnPropertyDescriptor(O, P)
5189 getOwnPropertyDescriptor: $getOwnPropertyDescriptor,
5190 // 19.1.2.7 Object.getOwnPropertyNames(O)
5191 getOwnPropertyNames: $getOwnPropertyNames,
5192 // 19.1.2.8 Object.getOwnPropertySymbols(O)
5193 getOwnPropertySymbols: $getOwnPropertySymbols
5194});
5195
5196// Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives
5197// https://bugs.chromium.org/p/v8/issues/detail?id=3443
5198var FAILS_ON_PRIMITIVES = $fails(function () { $GOPS.f(1); });
5199
5200$export($export.S + $export.F * FAILS_ON_PRIMITIVES, 'Object', {
5201 getOwnPropertySymbols: function getOwnPropertySymbols(it) {
5202 return $GOPS.f(toObject(it));
5203 }
5204});
5205
5206// 24.3.2 JSON.stringify(value [, replacer [, space]])
5207$JSON && $export($export.S + $export.F * (!USE_NATIVE || $fails(function () {
5208 var S = $Symbol();
5209 // MS Edge converts symbol values to JSON as {}
5210 // WebKit converts symbol values to JSON as null
5211 // V8 throws on boxed symbols
5212 return _stringify([S]) != '[null]' || _stringify({ a: S }) != '{}' || _stringify(Object(S)) != '{}';
5213})), 'JSON', {
5214 stringify: function stringify(it) {
5215 var args = [it];
5216 var i = 1;
5217 var replacer, $replacer;
5218 while (arguments.length > i) args.push(arguments[i++]);
5219 $replacer = replacer = args[1];
5220 if (!isObject(replacer) && it === undefined || isSymbol(it)) return; // IE8 returns string on undefined
5221 if (!isArray(replacer)) replacer = function (key, value) {
5222 if (typeof $replacer == 'function') value = $replacer.call(this, key, value);
5223 if (!isSymbol(value)) return value;
5224 };
5225 args[1] = replacer;
5226 return _stringify.apply($JSON, args);
5227 }
5228});
5229
5230// 19.4.3.4 Symbol.prototype[@@toPrimitive](hint)
5231$Symbol[PROTOTYPE][TO_PRIMITIVE] || __webpack_require__(13)($Symbol[PROTOTYPE], TO_PRIMITIVE, $Symbol[PROTOTYPE].valueOf);
5232// 19.4.3.5 Symbol.prototype[@@toStringTag]
5233setToStringTag($Symbol, 'Symbol');
5234// 20.2.1.9 Math[@@toStringTag]
5235setToStringTag(Math, 'Math', true);
5236// 24.3.3 JSON[@@toStringTag]
5237setToStringTag(global.JSON, 'JSON', true);
5238
5239
5240/***/ }),
5241/* 94 */
5242/***/ (function(module, exports, __webpack_require__) {
5243
5244var META = __webpack_require__(26)('meta');
5245var isObject = __webpack_require__(14);
5246var has = __webpack_require__(7);
5247var setDesc = __webpack_require__(6).f;
5248var id = 0;
5249var isExtensible = Object.isExtensible || function () {
5250 return true;
5251};
5252var FREEZE = !__webpack_require__(20)(function () {
5253 return isExtensible(Object.preventExtensions({}));
5254});
5255var setMeta = function (it) {
5256 setDesc(it, META, { value: {
5257 i: 'O' + ++id, // object ID
5258 w: {} // weak collections IDs
5259 } });
5260};
5261var fastKey = function (it, create) {
5262 // return primitive with prefix
5263 if (!isObject(it)) return typeof it == 'symbol' ? it : (typeof it == 'string' ? 'S' : 'P') + it;
5264 if (!has(it, META)) {
5265 // can't set metadata to uncaught frozen object
5266 if (!isExtensible(it)) return 'F';
5267 // not necessary to add metadata
5268 if (!create) return 'E';
5269 // add missing metadata
5270 setMeta(it);
5271 // return object ID
5272 } return it[META].i;
5273};
5274var getWeak = function (it, create) {
5275 if (!has(it, META)) {
5276 // can't set metadata to uncaught frozen object
5277 if (!isExtensible(it)) return true;
5278 // not necessary to add metadata
5279 if (!create) return false;
5280 // add missing metadata
5281 setMeta(it);
5282 // return hash weak collections IDs
5283 } return it[META].w;
5284};
5285// add metadata on freeze-family methods calling
5286var onFreeze = function (it) {
5287 if (FREEZE && meta.NEED && isExtensible(it) && !has(it, META)) setMeta(it);
5288 return it;
5289};
5290var meta = module.exports = {
5291 KEY: META,
5292 NEED: false,
5293 fastKey: fastKey,
5294 getWeak: getWeak,
5295 onFreeze: onFreeze
5296};
5297
5298
5299/***/ }),
5300/* 95 */
5301/***/ (function(module, exports, __webpack_require__) {
5302
5303// all enumerable object keys, includes symbols
5304var getKeys = __webpack_require__(24);
5305var gOPS = __webpack_require__(37);
5306var pIE = __webpack_require__(27);
5307module.exports = function (it) {
5308 var result = getKeys(it);
5309 var getSymbols = gOPS.f;
5310 if (getSymbols) {
5311 var symbols = getSymbols(it);
5312 var isEnum = pIE.f;
5313 var i = 0;
5314 var key;
5315 while (symbols.length > i) if (isEnum.call(it, key = symbols[i++])) result.push(key);
5316 } return result;
5317};
5318
5319
5320/***/ }),
5321/* 96 */
5322/***/ (function(module, exports, __webpack_require__) {
5323
5324// 7.2.2 IsArray(argument)
5325var cof = __webpack_require__(53);
5326module.exports = Array.isArray || function isArray(arg) {
5327 return cof(arg) == 'Array';
5328};
5329
5330
5331/***/ }),
5332/* 97 */
5333/***/ (function(module, exports, __webpack_require__) {
5334
5335// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window
5336var toIObject = __webpack_require__(15);
5337var gOPN = __webpack_require__(57).f;
5338var toString = {}.toString;
5339
5340var windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames
5341 ? Object.getOwnPropertyNames(window) : [];
5342
5343var getWindowNames = function (it) {
5344 try {
5345 return gOPN(it);
5346 } catch (e) {
5347 return windowNames.slice();
5348 }
5349};
5350
5351module.exports.f = function getOwnPropertyNames(it) {
5352 return windowNames && toString.call(it) == '[object Window]' ? getWindowNames(it) : gOPN(toIObject(it));
5353};
5354
5355
5356/***/ }),
5357/* 98 */
5358/***/ (function(module, exports) {
5359
5360
5361
5362/***/ }),
5363/* 99 */
5364/***/ (function(module, exports, __webpack_require__) {
5365
5366__webpack_require__(43)('asyncIterator');
5367
5368
5369/***/ }),
5370/* 100 */
5371/***/ (function(module, exports, __webpack_require__) {
5372
5373__webpack_require__(43)('observable');
5374
5375
5376/***/ }),
5377/* 101 */
5378/***/ (function(module, exports, __webpack_require__) {
5379
5380module.exports = { "default": __webpack_require__(102), __esModule: true };
5381
5382/***/ }),
5383/* 102 */
5384/***/ (function(module, exports, __webpack_require__) {
5385
5386__webpack_require__(103);
5387var $Object = __webpack_require__(3).Object;
5388module.exports = function defineProperty(it, key, desc) {
5389 return $Object.defineProperty(it, key, desc);
5390};
5391
5392
5393/***/ }),
5394/* 103 */
5395/***/ (function(module, exports, __webpack_require__) {
5396
5397var $export = __webpack_require__(12);
5398// 19.1.2.4 / 15.2.3.6 Object.defineProperty(O, P, Attributes)
5399$export($export.S + $export.F * !__webpack_require__(4), 'Object', { defineProperty: __webpack_require__(6).f });
5400
5401
5402/***/ }),
5403/* 104 */
5404/***/ (function(module, exports, __webpack_require__) {
5405
5406module.exports = { "default": __webpack_require__(105), __esModule: true };
5407
5408/***/ }),
5409/* 105 */
5410/***/ (function(module, exports, __webpack_require__) {
5411
5412__webpack_require__(106);
5413module.exports = __webpack_require__(3).Object.setPrototypeOf;
5414
5415
5416/***/ }),
5417/* 106 */
5418/***/ (function(module, exports, __webpack_require__) {
5419
5420// 19.1.3.19 Object.setPrototypeOf(O, proto)
5421var $export = __webpack_require__(12);
5422$export($export.S, 'Object', { setPrototypeOf: __webpack_require__(107).set });
5423
5424
5425/***/ }),
5426/* 107 */
5427/***/ (function(module, exports, __webpack_require__) {
5428
5429// Works with __proto__ only. Old v8 can't work with null proto objects.
5430/* eslint-disable no-proto */
5431var isObject = __webpack_require__(14);
5432var anObject = __webpack_require__(19);
5433var check = function (O, proto) {
5434 anObject(O);
5435 if (!isObject(proto) && proto !== null) throw TypeError(proto + ": can't set as prototype!");
5436};
5437module.exports = {
5438 set: Object.setPrototypeOf || ('__proto__' in {} ? // eslint-disable-line
5439 function (test, buggy, set) {
5440 try {
5441 set = __webpack_require__(48)(Function.call, __webpack_require__(58).f(Object.prototype, '__proto__').set, 2);
5442 set(test, []);
5443 buggy = !(test instanceof Array);
5444 } catch (e) { buggy = true; }
5445 return function setPrototypeOf(O, proto) {
5446 check(O, proto);
5447 if (buggy) O.__proto__ = proto;
5448 else set(O, proto);
5449 return O;
5450 };
5451 }({}, false) : undefined),
5452 check: check
5453};
5454
5455
5456/***/ }),
5457/* 108 */
5458/***/ (function(module, exports, __webpack_require__) {
5459
5460module.exports = { "default": __webpack_require__(109), __esModule: true };
5461
5462/***/ }),
5463/* 109 */
5464/***/ (function(module, exports, __webpack_require__) {
5465
5466__webpack_require__(110);
5467var $Object = __webpack_require__(3).Object;
5468module.exports = function create(P, D) {
5469 return $Object.create(P, D);
5470};
5471
5472
5473/***/ }),
5474/* 110 */
5475/***/ (function(module, exports, __webpack_require__) {
5476
5477var $export = __webpack_require__(12);
5478// 19.1.2.2 / 15.2.3.5 Object.create(O [, Properties])
5479$export($export.S, 'Object', { create: __webpack_require__(40) });
5480
5481
5482/***/ }),
5483/* 111 */
5484/***/ (function(module, exports, __webpack_require__) {
5485
5486"use strict";
5487/** @license React v16.9.0
5488 * react-is.production.min.js
5489 *
5490 * Copyright (c) Facebook, Inc. and its affiliates.
5491 *
5492 * This source code is licensed under the MIT license found in the
5493 * LICENSE file in the root directory of this source tree.
5494 */
5495
5496Object.defineProperty(exports,"__esModule",{value:!0});
5497var b="function"===typeof Symbol&&Symbol.for,c=b?Symbol.for("react.element"):60103,d=b?Symbol.for("react.portal"):60106,e=b?Symbol.for("react.fragment"):60107,f=b?Symbol.for("react.strict_mode"):60108,g=b?Symbol.for("react.profiler"):60114,h=b?Symbol.for("react.provider"):60109,k=b?Symbol.for("react.context"):60110,l=b?Symbol.for("react.async_mode"):60111,m=b?Symbol.for("react.concurrent_mode"):60111,n=b?Symbol.for("react.forward_ref"):60112,p=b?Symbol.for("react.suspense"):60113,q=b?Symbol.for("react.suspense_list"):
549860120,r=b?Symbol.for("react.memo"):60115,t=b?Symbol.for("react.lazy"):60116,v=b?Symbol.for("react.fundamental"):60117,w=b?Symbol.for("react.responder"):60118;function x(a){if("object"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case h:return a;default:return u}}case t:case r:case d:return u}}}function y(a){return x(a)===m}exports.typeOf=x;exports.AsyncMode=l;
5499exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;exports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;
5500exports.isValidElementType=function(a){return"string"===typeof a||"function"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||"object"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===v||a.$$typeof===w)};exports.isAsyncMode=function(a){return y(a)||x(a)===l};exports.isConcurrentMode=y;exports.isContextConsumer=function(a){return x(a)===k};exports.isContextProvider=function(a){return x(a)===h};
5501exports.isElement=function(a){return"object"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return x(a)===n};exports.isFragment=function(a){return x(a)===e};exports.isLazy=function(a){return x(a)===t};exports.isMemo=function(a){return x(a)===r};exports.isPortal=function(a){return x(a)===d};exports.isProfiler=function(a){return x(a)===g};exports.isStrictMode=function(a){return x(a)===f};exports.isSuspense=function(a){return x(a)===p};
5502
5503
5504/***/ }),
5505/* 112 */
5506/***/ (function(module, exports, __webpack_require__) {
5507
5508"use strict";
5509/* WEBPACK VAR INJECTION */(function(process) {/** @license React v16.9.0
5510 * react-is.development.js
5511 *
5512 * Copyright (c) Facebook, Inc. and its affiliates.
5513 *
5514 * This source code is licensed under the MIT license found in the
5515 * LICENSE file in the root directory of this source tree.
5516 */
5517
5518
5519
5520
5521
5522if (process.env.NODE_ENV !== "production") {
5523 (function() {
5524'use strict';
5525
5526Object.defineProperty(exports, '__esModule', { value: true });
5527
5528// The Symbol used to tag the ReactElement-like types. If there is no native Symbol
5529// nor polyfill, then a plain number is used for performance.
5530var hasSymbol = typeof Symbol === 'function' && Symbol.for;
5531
5532var REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;
5533var REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;
5534var REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;
5535var REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;
5536var REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;
5537var REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;
5538var REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace;
5539// TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary
5540// (unstable) APIs that have been removed. Can we remove the symbols?
5541var REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;
5542var REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;
5543var REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;
5544var REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;
5545var REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;
5546var REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;
5547var REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;
5548var REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;
5549var REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;
5550
5551function isValidElementType(type) {
5552 return typeof type === 'string' || typeof type === 'function' ||
5553 // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
5554 type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE);
5555}
5556
5557/**
5558 * Forked from fbjs/warning:
5559 * https://github.com/facebook/fbjs/blob/e66ba20ad5be433eb54423f2b097d829324d9de6/packages/fbjs/src/__forks__/warning.js
5560 *
5561 * Only change is we use console.warn instead of console.error,
5562 * and do nothing when 'console' is not supported.
5563 * This really simplifies the code.
5564 * ---
5565 * Similar to invariant but only logs a warning if the condition is not met.
5566 * This can be used to log issues in development environments in critical
5567 * paths. Removing the logging code for production environments will keep the
5568 * same logic and follow the same code paths.
5569 */
5570
5571var lowPriorityWarning = function () {};
5572
5573{
5574 var printWarning = function (format) {
5575 for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
5576 args[_key - 1] = arguments[_key];
5577 }
5578
5579 var argIndex = 0;
5580 var message = 'Warning: ' + format.replace(/%s/g, function () {
5581 return args[argIndex++];
5582 });
5583 if (typeof console !== 'undefined') {
5584 console.warn(message);
5585 }
5586 try {
5587 // --- Welcome to debugging React ---
5588 // This error was thrown as a convenience so that you can use this stack
5589 // to find the callsite that caused this warning to fire.
5590 throw new Error(message);
5591 } catch (x) {}
5592 };
5593
5594 lowPriorityWarning = function (condition, format) {
5595 if (format === undefined) {
5596 throw new Error('`lowPriorityWarning(condition, format, ...args)` requires a warning ' + 'message argument');
5597 }
5598 if (!condition) {
5599 for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) {
5600 args[_key2 - 2] = arguments[_key2];
5601 }
5602
5603 printWarning.apply(undefined, [format].concat(args));
5604 }
5605 };
5606}
5607
5608var lowPriorityWarning$1 = lowPriorityWarning;
5609
5610function typeOf(object) {
5611 if (typeof object === 'object' && object !== null) {
5612 var $$typeof = object.$$typeof;
5613 switch ($$typeof) {
5614 case REACT_ELEMENT_TYPE:
5615 var type = object.type;
5616
5617 switch (type) {
5618 case REACT_ASYNC_MODE_TYPE:
5619 case REACT_CONCURRENT_MODE_TYPE:
5620 case REACT_FRAGMENT_TYPE:
5621 case REACT_PROFILER_TYPE:
5622 case REACT_STRICT_MODE_TYPE:
5623 case REACT_SUSPENSE_TYPE:
5624 return type;
5625 default:
5626 var $$typeofType = type && type.$$typeof;
5627
5628 switch ($$typeofType) {
5629 case REACT_CONTEXT_TYPE:
5630 case REACT_FORWARD_REF_TYPE:
5631 case REACT_PROVIDER_TYPE:
5632 return $$typeofType;
5633 default:
5634 return $$typeof;
5635 }
5636 }
5637 case REACT_LAZY_TYPE:
5638 case REACT_MEMO_TYPE:
5639 case REACT_PORTAL_TYPE:
5640 return $$typeof;
5641 }
5642 }
5643
5644 return undefined;
5645}
5646
5647// AsyncMode is deprecated along with isAsyncMode
5648var AsyncMode = REACT_ASYNC_MODE_TYPE;
5649var ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;
5650var ContextConsumer = REACT_CONTEXT_TYPE;
5651var ContextProvider = REACT_PROVIDER_TYPE;
5652var Element = REACT_ELEMENT_TYPE;
5653var ForwardRef = REACT_FORWARD_REF_TYPE;
5654var Fragment = REACT_FRAGMENT_TYPE;
5655var Lazy = REACT_LAZY_TYPE;
5656var Memo = REACT_MEMO_TYPE;
5657var Portal = REACT_PORTAL_TYPE;
5658var Profiler = REACT_PROFILER_TYPE;
5659var StrictMode = REACT_STRICT_MODE_TYPE;
5660var Suspense = REACT_SUSPENSE_TYPE;
5661
5662var hasWarnedAboutDeprecatedIsAsyncMode = false;
5663
5664// AsyncMode should be deprecated
5665function isAsyncMode(object) {
5666 {
5667 if (!hasWarnedAboutDeprecatedIsAsyncMode) {
5668 hasWarnedAboutDeprecatedIsAsyncMode = true;
5669 lowPriorityWarning$1(false, 'The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');
5670 }
5671 }
5672 return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;
5673}
5674function isConcurrentMode(object) {
5675 return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;
5676}
5677function isContextConsumer(object) {
5678 return typeOf(object) === REACT_CONTEXT_TYPE;
5679}
5680function isContextProvider(object) {
5681 return typeOf(object) === REACT_PROVIDER_TYPE;
5682}
5683function isElement(object) {
5684 return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;
5685}
5686function isForwardRef(object) {
5687 return typeOf(object) === REACT_FORWARD_REF_TYPE;
5688}
5689function isFragment(object) {
5690 return typeOf(object) === REACT_FRAGMENT_TYPE;
5691}
5692function isLazy(object) {
5693 return typeOf(object) === REACT_LAZY_TYPE;
5694}
5695function isMemo(object) {
5696 return typeOf(object) === REACT_MEMO_TYPE;
5697}
5698function isPortal(object) {
5699 return typeOf(object) === REACT_PORTAL_TYPE;
5700}
5701function isProfiler(object) {
5702 return typeOf(object) === REACT_PROFILER_TYPE;
5703}
5704function isStrictMode(object) {
5705 return typeOf(object) === REACT_STRICT_MODE_TYPE;
5706}
5707function isSuspense(object) {
5708 return typeOf(object) === REACT_SUSPENSE_TYPE;
5709}
5710
5711exports.typeOf = typeOf;
5712exports.AsyncMode = AsyncMode;
5713exports.ConcurrentMode = ConcurrentMode;
5714exports.ContextConsumer = ContextConsumer;
5715exports.ContextProvider = ContextProvider;
5716exports.Element = Element;
5717exports.ForwardRef = ForwardRef;
5718exports.Fragment = Fragment;
5719exports.Lazy = Lazy;
5720exports.Memo = Memo;
5721exports.Portal = Portal;
5722exports.Profiler = Profiler;
5723exports.StrictMode = StrictMode;
5724exports.Suspense = Suspense;
5725exports.isValidElementType = isValidElementType;
5726exports.isAsyncMode = isAsyncMode;
5727exports.isConcurrentMode = isConcurrentMode;
5728exports.isContextConsumer = isContextConsumer;
5729exports.isContextProvider = isContextProvider;
5730exports.isElement = isElement;
5731exports.isForwardRef = isForwardRef;
5732exports.isFragment = isFragment;
5733exports.isLazy = isLazy;
5734exports.isMemo = isMemo;
5735exports.isPortal = isPortal;
5736exports.isProfiler = isProfiler;
5737exports.isStrictMode = isStrictMode;
5738exports.isSuspense = isSuspense;
5739 })();
5740}
5741
5742/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17)))
5743
5744/***/ }),
5745/* 113 */
5746/***/ (function(module, exports, __webpack_require__) {
5747
5748"use strict";
5749/* WEBPACK VAR INJECTION */(function(process) {/**
5750 * Copyright (c) 2013-present, Facebook, Inc.
5751 *
5752 * This source code is licensed under the MIT license found in the
5753 * LICENSE file in the root directory of this source tree.
5754 */
5755
5756
5757
5758var ReactIs = __webpack_require__(59);
5759var assign = __webpack_require__(114);
5760
5761var ReactPropTypesSecret = __webpack_require__(44);
5762var checkPropTypes = __webpack_require__(115);
5763
5764var has = Function.call.bind(Object.prototype.hasOwnProperty);
5765var printWarning = function() {};
5766
5767if (process.env.NODE_ENV !== 'production') {
5768 printWarning = function(text) {
5769 var message = 'Warning: ' + text;
5770 if (typeof console !== 'undefined') {
5771 console.error(message);
5772 }
5773 try {
5774 // --- Welcome to debugging React ---
5775 // This error was thrown as a convenience so that you can use this stack
5776 // to find the callsite that caused this warning to fire.
5777 throw new Error(message);
5778 } catch (x) {}
5779 };
5780}
5781
5782function emptyFunctionThatReturnsNull() {
5783 return null;
5784}
5785
5786module.exports = function(isValidElement, throwOnDirectAccess) {
5787 /* global Symbol */
5788 var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;
5789 var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.
5790
5791 /**
5792 * Returns the iterator method function contained on the iterable object.
5793 *
5794 * Be sure to invoke the function with the iterable as context:
5795 *
5796 * var iteratorFn = getIteratorFn(myIterable);
5797 * if (iteratorFn) {
5798 * var iterator = iteratorFn.call(myIterable);
5799 * ...
5800 * }
5801 *
5802 * @param {?object} maybeIterable
5803 * @return {?function}
5804 */
5805 function getIteratorFn(maybeIterable) {
5806 var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);
5807 if (typeof iteratorFn === 'function') {
5808 return iteratorFn;
5809 }
5810 }
5811
5812 /**
5813 * Collection of methods that allow declaration and validation of props that are
5814 * supplied to React components. Example usage:
5815 *
5816 * var Props = require('ReactPropTypes');
5817 * var MyArticle = React.createClass({
5818 * propTypes: {
5819 * // An optional string prop named "description".
5820 * description: Props.string,
5821 *
5822 * // A required enum prop named "category".
5823 * category: Props.oneOf(['News','Photos']).isRequired,
5824 *
5825 * // A prop named "dialog" that requires an instance of Dialog.
5826 * dialog: Props.instanceOf(Dialog).isRequired
5827 * },
5828 * render: function() { ... }
5829 * });
5830 *
5831 * A more formal specification of how these methods are used:
5832 *
5833 * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)
5834 * decl := ReactPropTypes.{type}(.isRequired)?
5835 *
5836 * Each and every declaration produces a function with the same signature. This
5837 * allows the creation of custom validation functions. For example:
5838 *
5839 * var MyLink = React.createClass({
5840 * propTypes: {
5841 * // An optional string or URI prop named "href".
5842 * href: function(props, propName, componentName) {
5843 * var propValue = props[propName];
5844 * if (propValue != null && typeof propValue !== 'string' &&
5845 * !(propValue instanceof URI)) {
5846 * return new Error(
5847 * 'Expected a string or an URI for ' + propName + ' in ' +
5848 * componentName
5849 * );
5850 * }
5851 * }
5852 * },
5853 * render: function() {...}
5854 * });
5855 *
5856 * @internal
5857 */
5858
5859 var ANONYMOUS = '<<anonymous>>';
5860
5861 // Important!
5862 // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.
5863 var ReactPropTypes = {
5864 array: createPrimitiveTypeChecker('array'),
5865 bool: createPrimitiveTypeChecker('boolean'),
5866 func: createPrimitiveTypeChecker('function'),
5867 number: createPrimitiveTypeChecker('number'),
5868 object: createPrimitiveTypeChecker('object'),
5869 string: createPrimitiveTypeChecker('string'),
5870 symbol: createPrimitiveTypeChecker('symbol'),
5871
5872 any: createAnyTypeChecker(),
5873 arrayOf: createArrayOfTypeChecker,
5874 element: createElementTypeChecker(),
5875 elementType: createElementTypeTypeChecker(),
5876 instanceOf: createInstanceTypeChecker,
5877 node: createNodeChecker(),
5878 objectOf: createObjectOfTypeChecker,
5879 oneOf: createEnumTypeChecker,
5880 oneOfType: createUnionTypeChecker,
5881 shape: createShapeTypeChecker,
5882 exact: createStrictShapeTypeChecker,
5883 };
5884
5885 /**
5886 * inlined Object.is polyfill to avoid requiring consumers ship their own
5887 * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is
5888 */
5889 /*eslint-disable no-self-compare*/
5890 function is(x, y) {
5891 // SameValue algorithm
5892 if (x === y) {
5893 // Steps 1-5, 7-10
5894 // Steps 6.b-6.e: +0 != -0
5895 return x !== 0 || 1 / x === 1 / y;
5896 } else {
5897 // Step 6.a: NaN == NaN
5898 return x !== x && y !== y;
5899 }
5900 }
5901 /*eslint-enable no-self-compare*/
5902
5903 /**
5904 * We use an Error-like object for backward compatibility as people may call
5905 * PropTypes directly and inspect their output. However, we don't use real
5906 * Errors anymore. We don't inspect their stack anyway, and creating them
5907 * is prohibitively expensive if they are created too often, such as what
5908 * happens in oneOfType() for any type before the one that matched.
5909 */
5910 function PropTypeError(message) {
5911 this.message = message;
5912 this.stack = '';
5913 }
5914 // Make `instanceof Error` still work for returned errors.
5915 PropTypeError.prototype = Error.prototype;
5916
5917 function createChainableTypeChecker(validate) {
5918 if (process.env.NODE_ENV !== 'production') {
5919 var manualPropTypeCallCache = {};
5920 var manualPropTypeWarningCount = 0;
5921 }
5922 function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {
5923 componentName = componentName || ANONYMOUS;
5924 propFullName = propFullName || propName;
5925
5926 if (secret !== ReactPropTypesSecret) {
5927 if (throwOnDirectAccess) {
5928 // New behavior only for users of `prop-types` package
5929 var err = new Error(
5930 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +
5931 'Use `PropTypes.checkPropTypes()` to call them. ' +
5932 'Read more at http://fb.me/use-check-prop-types'
5933 );
5934 err.name = 'Invariant Violation';
5935 throw err;
5936 } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {
5937 // Old behavior for people using React.PropTypes
5938 var cacheKey = componentName + ':' + propName;
5939 if (
5940 !manualPropTypeCallCache[cacheKey] &&
5941 // Avoid spamming the console because they are often not actionable except for lib authors
5942 manualPropTypeWarningCount < 3
5943 ) {
5944 printWarning(
5945 'You are manually calling a React.PropTypes validation ' +
5946 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +
5947 'and will throw in the standalone `prop-types` package. ' +
5948 'You may be seeing this warning due to a third-party PropTypes ' +
5949 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'
5950 );
5951 manualPropTypeCallCache[cacheKey] = true;
5952 manualPropTypeWarningCount++;
5953 }
5954 }
5955 }
5956 if (props[propName] == null) {
5957 if (isRequired) {
5958 if (props[propName] === null) {
5959 return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));
5960 }
5961 return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));
5962 }
5963 return null;
5964 } else {
5965 return validate(props, propName, componentName, location, propFullName);
5966 }
5967 }
5968
5969 var chainedCheckType = checkType.bind(null, false);
5970 chainedCheckType.isRequired = checkType.bind(null, true);
5971
5972 return chainedCheckType;
5973 }
5974
5975 function createPrimitiveTypeChecker(expectedType) {
5976 function validate(props, propName, componentName, location, propFullName, secret) {
5977 var propValue = props[propName];
5978 var propType = getPropType(propValue);
5979 if (propType !== expectedType) {
5980 // `propValue` being instance of, say, date/regexp, pass the 'object'
5981 // check, but we can offer a more precise error message here rather than
5982 // 'of type `object`'.
5983 var preciseType = getPreciseType(propValue);
5984
5985 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'));
5986 }
5987 return null;
5988 }
5989 return createChainableTypeChecker(validate);
5990 }
5991
5992 function createAnyTypeChecker() {
5993 return createChainableTypeChecker(emptyFunctionThatReturnsNull);
5994 }
5995
5996 function createArrayOfTypeChecker(typeChecker) {
5997 function validate(props, propName, componentName, location, propFullName) {
5998 if (typeof typeChecker !== 'function') {
5999 return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');
6000 }
6001 var propValue = props[propName];
6002 if (!Array.isArray(propValue)) {
6003 var propType = getPropType(propValue);
6004 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));
6005 }
6006 for (var i = 0; i < propValue.length; i++) {
6007 var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);
6008 if (error instanceof Error) {
6009 return error;
6010 }
6011 }
6012 return null;
6013 }
6014 return createChainableTypeChecker(validate);
6015 }
6016
6017 function createElementTypeChecker() {
6018 function validate(props, propName, componentName, location, propFullName) {
6019 var propValue = props[propName];
6020 if (!isValidElement(propValue)) {
6021 var propType = getPropType(propValue);
6022 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));
6023 }
6024 return null;
6025 }
6026 return createChainableTypeChecker(validate);
6027 }
6028
6029 function createElementTypeTypeChecker() {
6030 function validate(props, propName, componentName, location, propFullName) {
6031 var propValue = props[propName];
6032 if (!ReactIs.isValidElementType(propValue)) {
6033 var propType = getPropType(propValue);
6034 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));
6035 }
6036 return null;
6037 }
6038 return createChainableTypeChecker(validate);
6039 }
6040
6041 function createInstanceTypeChecker(expectedClass) {
6042 function validate(props, propName, componentName, location, propFullName) {
6043 if (!(props[propName] instanceof expectedClass)) {
6044 var expectedClassName = expectedClass.name || ANONYMOUS;
6045 var actualClassName = getClassName(props[propName]);
6046 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));
6047 }
6048 return null;
6049 }
6050 return createChainableTypeChecker(validate);
6051 }
6052
6053 function createEnumTypeChecker(expectedValues) {
6054 if (!Array.isArray(expectedValues)) {
6055 if (process.env.NODE_ENV !== 'production') {
6056 if (arguments.length > 1) {
6057 printWarning(
6058 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +
6059 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'
6060 );
6061 } else {
6062 printWarning('Invalid argument supplied to oneOf, expected an array.');
6063 }
6064 }
6065 return emptyFunctionThatReturnsNull;
6066 }
6067
6068 function validate(props, propName, componentName, location, propFullName) {
6069 var propValue = props[propName];
6070 for (var i = 0; i < expectedValues.length; i++) {
6071 if (is(propValue, expectedValues[i])) {
6072 return null;
6073 }
6074 }
6075
6076 var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {
6077 var type = getPreciseType(value);
6078 if (type === 'symbol') {
6079 return String(value);
6080 }
6081 return value;
6082 });
6083 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));
6084 }
6085 return createChainableTypeChecker(validate);
6086 }
6087
6088 function createObjectOfTypeChecker(typeChecker) {
6089 function validate(props, propName, componentName, location, propFullName) {
6090 if (typeof typeChecker !== 'function') {
6091 return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');
6092 }
6093 var propValue = props[propName];
6094 var propType = getPropType(propValue);
6095 if (propType !== 'object') {
6096 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));
6097 }
6098 for (var key in propValue) {
6099 if (has(propValue, key)) {
6100 var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);
6101 if (error instanceof Error) {
6102 return error;
6103 }
6104 }
6105 }
6106 return null;
6107 }
6108 return createChainableTypeChecker(validate);
6109 }
6110
6111 function createUnionTypeChecker(arrayOfTypeCheckers) {
6112 if (!Array.isArray(arrayOfTypeCheckers)) {
6113 process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;
6114 return emptyFunctionThatReturnsNull;
6115 }
6116
6117 for (var i = 0; i < arrayOfTypeCheckers.length; i++) {
6118 var checker = arrayOfTypeCheckers[i];
6119 if (typeof checker !== 'function') {
6120 printWarning(
6121 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +
6122 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'
6123 );
6124 return emptyFunctionThatReturnsNull;
6125 }
6126 }
6127
6128 function validate(props, propName, componentName, location, propFullName) {
6129 for (var i = 0; i < arrayOfTypeCheckers.length; i++) {
6130 var checker = arrayOfTypeCheckers[i];
6131 if (checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret) == null) {
6132 return null;
6133 }
6134 }
6135
6136 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`.'));
6137 }
6138 return createChainableTypeChecker(validate);
6139 }
6140
6141 function createNodeChecker() {
6142 function validate(props, propName, componentName, location, propFullName) {
6143 if (!isNode(props[propName])) {
6144 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));
6145 }
6146 return null;
6147 }
6148 return createChainableTypeChecker(validate);
6149 }
6150
6151 function createShapeTypeChecker(shapeTypes) {
6152 function validate(props, propName, componentName, location, propFullName) {
6153 var propValue = props[propName];
6154 var propType = getPropType(propValue);
6155 if (propType !== 'object') {
6156 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));
6157 }
6158 for (var key in shapeTypes) {
6159 var checker = shapeTypes[key];
6160 if (!checker) {
6161 continue;
6162 }
6163 var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);
6164 if (error) {
6165 return error;
6166 }
6167 }
6168 return null;
6169 }
6170 return createChainableTypeChecker(validate);
6171 }
6172
6173 function createStrictShapeTypeChecker(shapeTypes) {
6174 function validate(props, propName, componentName, location, propFullName) {
6175 var propValue = props[propName];
6176 var propType = getPropType(propValue);
6177 if (propType !== 'object') {
6178 return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));
6179 }
6180 // We need to check all keys in case some are required but missing from
6181 // props.
6182 var allKeys = assign({}, props[propName], shapeTypes);
6183 for (var key in allKeys) {
6184 var checker = shapeTypes[key];
6185 if (!checker) {
6186 return new PropTypeError(
6187 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +
6188 '\nBad object: ' + JSON.stringify(props[propName], null, ' ') +
6189 '\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')
6190 );
6191 }
6192 var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);
6193 if (error) {
6194 return error;
6195 }
6196 }
6197 return null;
6198 }
6199
6200 return createChainableTypeChecker(validate);
6201 }
6202
6203 function isNode(propValue) {
6204 switch (typeof propValue) {
6205 case 'number':
6206 case 'string':
6207 case 'undefined':
6208 return true;
6209 case 'boolean':
6210 return !propValue;
6211 case 'object':
6212 if (Array.isArray(propValue)) {
6213 return propValue.every(isNode);
6214 }
6215 if (propValue === null || isValidElement(propValue)) {
6216 return true;
6217 }
6218
6219 var iteratorFn = getIteratorFn(propValue);
6220 if (iteratorFn) {
6221 var iterator = iteratorFn.call(propValue);
6222 var step;
6223 if (iteratorFn !== propValue.entries) {
6224 while (!(step = iterator.next()).done) {
6225 if (!isNode(step.value)) {
6226 return false;
6227 }
6228 }
6229 } else {
6230 // Iterator will provide entry [k,v] tuples rather than values.
6231 while (!(step = iterator.next()).done) {
6232 var entry = step.value;
6233 if (entry) {
6234 if (!isNode(entry[1])) {
6235 return false;
6236 }
6237 }
6238 }
6239 }
6240 } else {
6241 return false;
6242 }
6243
6244 return true;
6245 default:
6246 return false;
6247 }
6248 }
6249
6250 function isSymbol(propType, propValue) {
6251 // Native Symbol.
6252 if (propType === 'symbol') {
6253 return true;
6254 }
6255
6256 // falsy value can't be a Symbol
6257 if (!propValue) {
6258 return false;
6259 }
6260
6261 // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'
6262 if (propValue['@@toStringTag'] === 'Symbol') {
6263 return true;
6264 }
6265
6266 // Fallback for non-spec compliant Symbols which are polyfilled.
6267 if (typeof Symbol === 'function' && propValue instanceof Symbol) {
6268 return true;
6269 }
6270
6271 return false;
6272 }
6273
6274 // Equivalent of `typeof` but with special handling for array and regexp.
6275 function getPropType(propValue) {
6276 var propType = typeof propValue;
6277 if (Array.isArray(propValue)) {
6278 return 'array';
6279 }
6280 if (propValue instanceof RegExp) {
6281 // Old webkits (at least until Android 4.0) return 'function' rather than
6282 // 'object' for typeof a RegExp. We'll normalize this here so that /bla/
6283 // passes PropTypes.object.
6284 return 'object';
6285 }
6286 if (isSymbol(propType, propValue)) {
6287 return 'symbol';
6288 }
6289 return propType;
6290 }
6291
6292 // This handles more types than `getPropType`. Only used for error messages.
6293 // See `createPrimitiveTypeChecker`.
6294 function getPreciseType(propValue) {
6295 if (typeof propValue === 'undefined' || propValue === null) {
6296 return '' + propValue;
6297 }
6298 var propType = getPropType(propValue);
6299 if (propType === 'object') {
6300 if (propValue instanceof Date) {
6301 return 'date';
6302 } else if (propValue instanceof RegExp) {
6303 return 'regexp';
6304 }
6305 }
6306 return propType;
6307 }
6308
6309 // Returns a string that is postfixed to a warning about an invalid type.
6310 // For example, "undefined" or "of type array"
6311 function getPostfixForTypeWarning(value) {
6312 var type = getPreciseType(value);
6313 switch (type) {
6314 case 'array':
6315 case 'object':
6316 return 'an ' + type;
6317 case 'boolean':
6318 case 'date':
6319 case 'regexp':
6320 return 'a ' + type;
6321 default:
6322 return type;
6323 }
6324 }
6325
6326 // Returns class name of the object, if any.
6327 function getClassName(propValue) {
6328 if (!propValue.constructor || !propValue.constructor.name) {
6329 return ANONYMOUS;
6330 }
6331 return propValue.constructor.name;
6332 }
6333
6334 ReactPropTypes.checkPropTypes = checkPropTypes;
6335 ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;
6336 ReactPropTypes.PropTypes = ReactPropTypes;
6337
6338 return ReactPropTypes;
6339};
6340
6341/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17)))
6342
6343/***/ }),
6344/* 114 */
6345/***/ (function(module, exports, __webpack_require__) {
6346
6347"use strict";
6348/*
6349object-assign
6350(c) Sindre Sorhus
6351@license MIT
6352*/
6353
6354
6355/* eslint-disable no-unused-vars */
6356var getOwnPropertySymbols = Object.getOwnPropertySymbols;
6357var hasOwnProperty = Object.prototype.hasOwnProperty;
6358var propIsEnumerable = Object.prototype.propertyIsEnumerable;
6359
6360function toObject(val) {
6361 if (val === null || val === undefined) {
6362 throw new TypeError('Object.assign cannot be called with null or undefined');
6363 }
6364
6365 return Object(val);
6366}
6367
6368function shouldUseNative() {
6369 try {
6370 if (!Object.assign) {
6371 return false;
6372 }
6373
6374 // Detect buggy property enumeration order in older V8 versions.
6375
6376 // https://bugs.chromium.org/p/v8/issues/detail?id=4118
6377 var test1 = new String('abc'); // eslint-disable-line no-new-wrappers
6378 test1[5] = 'de';
6379 if (Object.getOwnPropertyNames(test1)[0] === '5') {
6380 return false;
6381 }
6382
6383 // https://bugs.chromium.org/p/v8/issues/detail?id=3056
6384 var test2 = {};
6385 for (var i = 0; i < 10; i++) {
6386 test2['_' + String.fromCharCode(i)] = i;
6387 }
6388 var order2 = Object.getOwnPropertyNames(test2).map(function (n) {
6389 return test2[n];
6390 });
6391 if (order2.join('') !== '0123456789') {
6392 return false;
6393 }
6394
6395 // https://bugs.chromium.org/p/v8/issues/detail?id=3056
6396 var test3 = {};
6397 'abcdefghijklmnopqrst'.split('').forEach(function (letter) {
6398 test3[letter] = letter;
6399 });
6400 if (Object.keys(Object.assign({}, test3)).join('') !==
6401 'abcdefghijklmnopqrst') {
6402 return false;
6403 }
6404
6405 return true;
6406 } catch (err) {
6407 // We don't expect any of the above to throw, but better to be safe.
6408 return false;
6409 }
6410}
6411
6412module.exports = shouldUseNative() ? Object.assign : function (target, source) {
6413 var from;
6414 var to = toObject(target);
6415 var symbols;
6416
6417 for (var s = 1; s < arguments.length; s++) {
6418 from = Object(arguments[s]);
6419
6420 for (var key in from) {
6421 if (hasOwnProperty.call(from, key)) {
6422 to[key] = from[key];
6423 }
6424 }
6425
6426 if (getOwnPropertySymbols) {
6427 symbols = getOwnPropertySymbols(from);
6428 for (var i = 0; i < symbols.length; i++) {
6429 if (propIsEnumerable.call(from, symbols[i])) {
6430 to[symbols[i]] = from[symbols[i]];
6431 }
6432 }
6433 }
6434 }
6435
6436 return to;
6437};
6438
6439
6440/***/ }),
6441/* 115 */
6442/***/ (function(module, exports, __webpack_require__) {
6443
6444"use strict";
6445/* WEBPACK VAR INJECTION */(function(process) {/**
6446 * Copyright (c) 2013-present, Facebook, Inc.
6447 *
6448 * This source code is licensed under the MIT license found in the
6449 * LICENSE file in the root directory of this source tree.
6450 */
6451
6452
6453
6454var printWarning = function() {};
6455
6456if (process.env.NODE_ENV !== 'production') {
6457 var ReactPropTypesSecret = __webpack_require__(44);
6458 var loggedTypeFailures = {};
6459 var has = Function.call.bind(Object.prototype.hasOwnProperty);
6460
6461 printWarning = function(text) {
6462 var message = 'Warning: ' + text;
6463 if (typeof console !== 'undefined') {
6464 console.error(message);
6465 }
6466 try {
6467 // --- Welcome to debugging React ---
6468 // This error was thrown as a convenience so that you can use this stack
6469 // to find the callsite that caused this warning to fire.
6470 throw new Error(message);
6471 } catch (x) {}
6472 };
6473}
6474
6475/**
6476 * Assert that the values match with the type specs.
6477 * Error messages are memorized and will only be shown once.
6478 *
6479 * @param {object} typeSpecs Map of name to a ReactPropType
6480 * @param {object} values Runtime values that need to be type-checked
6481 * @param {string} location e.g. "prop", "context", "child context"
6482 * @param {string} componentName Name of the component for error messages.
6483 * @param {?Function} getStack Returns the component stack.
6484 * @private
6485 */
6486function checkPropTypes(typeSpecs, values, location, componentName, getStack) {
6487 if (process.env.NODE_ENV !== 'production') {
6488 for (var typeSpecName in typeSpecs) {
6489 if (has(typeSpecs, typeSpecName)) {
6490 var error;
6491 // Prop type validation may throw. In case they do, we don't want to
6492 // fail the render phase where it didn't fail before. So we log it.
6493 // After these have been cleaned up, we'll let them throw.
6494 try {
6495 // This is intentionally an invariant that gets caught. It's the same
6496 // behavior as without this statement except with a better message.
6497 if (typeof typeSpecs[typeSpecName] !== 'function') {
6498 var err = Error(
6499 (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +
6500 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.'
6501 );
6502 err.name = 'Invariant Violation';
6503 throw err;
6504 }
6505 error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);
6506 } catch (ex) {
6507 error = ex;
6508 }
6509 if (error && !(error instanceof Error)) {
6510 printWarning(
6511 (componentName || 'React class') + ': type specification of ' +
6512 location + ' `' + typeSpecName + '` is invalid; the type checker ' +
6513 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +
6514 'You may have forgotten to pass an argument to the type checker ' +
6515 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +
6516 'shape all require an argument).'
6517 );
6518 }
6519 if (error instanceof Error && !(error.message in loggedTypeFailures)) {
6520 // Only monitor this failure once because there tends to be a lot of the
6521 // same error.
6522 loggedTypeFailures[error.message] = true;
6523
6524 var stack = getStack ? getStack() : '';
6525
6526 printWarning(
6527 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')
6528 );
6529 }
6530 }
6531 }
6532 }
6533}
6534
6535/**
6536 * Resets warning cache when testing.
6537 *
6538 * @private
6539 */
6540checkPropTypes.resetWarningCache = function() {
6541 if (process.env.NODE_ENV !== 'production') {
6542 loggedTypeFailures = {};
6543 }
6544}
6545
6546module.exports = checkPropTypes;
6547
6548/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17)))
6549
6550/***/ }),
6551/* 116 */
6552/***/ (function(module, exports, __webpack_require__) {
6553
6554"use strict";
6555/**
6556 * Copyright (c) 2013-present, Facebook, Inc.
6557 *
6558 * This source code is licensed under the MIT license found in the
6559 * LICENSE file in the root directory of this source tree.
6560 */
6561
6562
6563
6564var ReactPropTypesSecret = __webpack_require__(44);
6565
6566function emptyFunction() {}
6567function emptyFunctionWithReset() {}
6568emptyFunctionWithReset.resetWarningCache = emptyFunction;
6569
6570module.exports = function() {
6571 function shim(props, propName, componentName, location, propFullName, secret) {
6572 if (secret === ReactPropTypesSecret) {
6573 // It is still safe when called from React.
6574 return;
6575 }
6576 var err = new Error(
6577 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +
6578 'Use PropTypes.checkPropTypes() to call them. ' +
6579 'Read more at http://fb.me/use-check-prop-types'
6580 );
6581 err.name = 'Invariant Violation';
6582 throw err;
6583 };
6584 shim.isRequired = shim;
6585 function getShim() {
6586 return shim;
6587 };
6588 // Important!
6589 // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.
6590 var ReactPropTypes = {
6591 array: shim,
6592 bool: shim,
6593 func: shim,
6594 number: shim,
6595 object: shim,
6596 string: shim,
6597 symbol: shim,
6598
6599 any: shim,
6600 arrayOf: getShim,
6601 element: shim,
6602 elementType: shim,
6603 instanceOf: getShim,
6604 node: shim,
6605 objectOf: getShim,
6606 oneOf: getShim,
6607 oneOfType: getShim,
6608 shape: getShim,
6609 exact: getShim,
6610
6611 checkPropTypes: emptyFunctionWithReset,
6612 resetWarningCache: emptyFunction
6613 };
6614
6615 ReactPropTypes.PropTypes = ReactPropTypes;
6616
6617 return ReactPropTypes;
6618};
6619
6620
6621/***/ }),
6622/* 117 */
6623/***/ (function(module, __webpack_exports__, __webpack_require__) {
6624
6625"use strict";
6626/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__ = __webpack_require__(0);
6627/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__);
6628/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_style_utils__ = __webpack_require__(29);
6629/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_style_utils___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_style_utils__);
6630/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__util_js__ = __webpack_require__(21);
6631/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__plugins__ = __webpack_require__(46);
6632
6633/* eslint-disable func-names, no-console */
6634
6635
6636
6637
6638var StylePlugin = function StylePlugin(target, vars, type) {
6639 this.target = target;
6640 this.vars = vars;
6641 this.type = type;
6642 this.propsData = {};
6643 this.setDefaultData();
6644};
6645StylePlugin.prototype = {
6646 name: 'style'
6647};
6648var p = StylePlugin.prototype;
6649p.getTweenData = function (key, $vars) {
6650 var data = {
6651 data: {},
6652 dataType: {},
6653 dataUnit: {},
6654 dataCount: {},
6655 dataSplitStr: {}
6656 };
6657 var vars = $vars;
6658 if (__WEBPACK_IMPORTED_MODULE_2__util_js__["i" /* styleValueToArray */][key]) {
6659 vars = vars.toString().split(' ');
6660 vars = vars.map(function (c) {
6661 return typeof $vars === 'number' ? c + 'px' : c;
6662 });
6663 vars[1] = vars[1] || vars[0];
6664 vars[2] = vars[2] || vars[0];
6665 vars[3] = vars[3] || vars[1] || vars[0];
6666 vars = vars.join(' ');
6667 }
6668 if (key.match(/colo|fill|storker/i)) {
6669 data.data[key] = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["parseColor"])(vars);
6670 data.dataType[key] = 'color';
6671 } else if (key === 'strokeDasharray') {
6672 data.data[key] = vars.split(',');
6673 data.dataType[key] = 'strokeDasharray';
6674 } else if (key.match(/shadow/i)) {
6675 data.data[key] = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["parseShadow"])(vars);
6676 data.dataType[key] = 'shadow';
6677 } else if (typeof vars === 'string' && vars.split(/[\s|,]/).length > 1) {
6678 data.data[key] = vars.split(/[\s|,]/);
6679 data.dataSplitStr[key] = vars.replace(/[^\s|,]/g, '').replace(/\s+/g, ' ');
6680 data.dataType[key] = 'string';
6681 } else {
6682 data.data[key] = vars;
6683 data.dataType[key] = 'other';
6684 }
6685 if (Array.isArray(data.data[key])) {
6686 data.dataUnit[key] = data.data[key].map(function (_item) {
6687 return _item.toString().replace(/[^a-z|%]/g, '');
6688 });
6689 data.dataCount[key] = data.data[key].map(function (_item) {
6690 return _item.toString().replace(/[^+|=|-]/g, '');
6691 });
6692
6693 data.data[key] = data.data[key].map(function (_item) {
6694 return !parseFloat(_item) && parseFloat(_item) !== 0 ? _item : parseFloat(_item);
6695 });
6696 } else {
6697 data.dataUnit[key] = data.data[key].toString().replace(/[^a-z|%]/g, '');
6698 data.dataCount[key] = data.data[key].toString().replace(/[^+|=|-]/g, '');
6699 var d = parseFloat(data.data[key].toString().replace(/[a-z|%|=]/g, ''));
6700 data.data[key] = !d && d !== 0 ? data.data[key] : d;
6701 }
6702 return data;
6703};
6704p.setDefaultData = function () {
6705 var _this = this;
6706
6707 this.propsData.data = {};
6708 this.propsData.dataType = {};
6709 this.propsData.dataUnit = {};
6710 this.propsData.dataCount = {};
6711 this.propsData.dataSplitStr = {};
6712 Object.keys(this.vars).forEach(function (_key) {
6713 if (_key in __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */]) {
6714 _this.propsData.data[_key] = new __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */][_key](_this.target, _this.vars[_key]);
6715 return;
6716 }
6717 var key = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["getGsapType"])(_key);
6718 var _data = _this.getTweenData(key, _this.vars[_key]);
6719 _this.propsData.data[key] = _data.data[key];
6720 _this.propsData.dataType[key] = _data.dataType[key];
6721 _this.propsData.dataUnit[key] = _data.dataUnit[key];
6722 _this.propsData.dataCount[key] = _data.dataCount[key];
6723 if (_data.dataSplitStr[key]) {
6724 _this.propsData.dataSplitStr[key] = _data.dataSplitStr[key];
6725 }
6726 });
6727};
6728p.convertToMarksArray = function (computedStyle, unit, key, data, i) {
6729 var startUnit = data.toString().replace(/[^a-z|%]/g, '');
6730 var endUnit = unit[i];
6731 if (startUnit === endUnit) {
6732 return parseFloat(data);
6733 } else if (!parseFloat(data) && parseFloat(data) !== 0) {
6734 return data;
6735 }
6736 return Object(__WEBPACK_IMPORTED_MODULE_2__util_js__["h" /* startConvertToEndUnit */])(this.target, computedStyle, key, data, startUnit, endUnit, null, key === 'transformOrigin' && !i);
6737};
6738p.getAnimStart = function (computedStyle, tween, isSvg) {
6739 var _this2 = this;
6740
6741 var style = {};
6742 var tweenStyle = tween.style || {};
6743 var transform = void 0;
6744 Object.keys(this.propsData.data).forEach(function (key) {
6745 var cssName = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["isConvert"])(key);
6746 var startData = tweenStyle[cssName] || computedStyle[cssName];
6747 var fixed = computedStyle.position === 'fixed';
6748 if (!startData || startData === 'none' || startData === 'auto') {
6749 startData = '';
6750 }
6751 var endUnit = void 0;
6752 var startUnit = void 0;
6753 if (key in __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */]) {
6754 if (key === 'bezier') {
6755 _this2.transform = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["checkStyleName"])('transform');
6756 startData = computedStyle[isSvg ? 'transformSVG' : _this2.transform];
6757 transform = transform || (tweenStyle.transform ? __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, tweenStyle.transform) : style.transform || Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["getTransform"])(startData));
6758 style.transform = transform;
6759 }
6760 _this2.propsData.data[key].getAnimStart(computedStyle, isSvg);
6761 } else if (cssName === 'transform') {
6762 _this2.transform = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["checkStyleName"])('transform');
6763 startData = computedStyle[isSvg ? 'transformSVG' : _this2.transform];
6764 endUnit = _this2.propsData.dataUnit[key];
6765 transform = transform || (tweenStyle.transform ? __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, tweenStyle.transform) : style.transform || Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["getTransform"])(startData));
6766 var unitReg = /%|vw|vh|em|rem/i;
6767 if (endUnit && endUnit.match(unitReg)) {
6768 transform[key] = transform[key] && transform[key].toString().match(unitReg) ? parseFloat(transform[key]) : Object(__WEBPACK_IMPORTED_MODULE_2__util_js__["h" /* startConvertToEndUnit */])(_this2.target, computedStyle, key, transform[key], null, endUnit);
6769 }
6770 style.transform = transform;
6771 } else if (cssName === 'filter') {
6772 if (tweenStyle[cssName]) {
6773 startData = tweenStyle[cssName];
6774 } else {
6775 _this2.filterName = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["checkStyleName"])('filter') || 'filter';
6776 startData = computedStyle[_this2.filterName];
6777 _this2.filterObject = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, _this2.filterObject, Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["splitFilterToObject"])(startData));
6778 startData = _this2.filterObject[key] || 0;
6779 }
6780 startUnit = startData.toString().replace(/[^a-z|%]/g, '');
6781 endUnit = _this2.propsData.dataUnit[key];
6782 if (endUnit !== startUnit) {
6783 startData = Object(__WEBPACK_IMPORTED_MODULE_2__util_js__["h" /* startConvertToEndUnit */])(_this2.target, computedStyle, cssName, parseFloat(startData), startUnit, endUnit, fixed);
6784 }
6785 style[key] = parseFloat(startData);
6786 } else if (key.match(/color|fill/i) || key === 'stroke') {
6787 startData = !startData && key === 'stroke' ? 'rgba(255, 255, 255, 0)' : startData;
6788 style[cssName] = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["parseColor"])(startData);
6789 } else if (key.match(/shadow/i)) {
6790 startData = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["parseShadow"])(startData);
6791 endUnit = _this2.propsData.dataUnit[key];
6792 startData = startData.map(_this2.convertToMarksArray.bind(_this2, computedStyle, endUnit, key));
6793 style[cssName] = startData;
6794 } else if (Array.isArray(_this2.propsData.data[key])) {
6795 startData = startData.split(/[\s|,]/).filter(function (c) {
6796 return c || c === 0;
6797 });
6798 endUnit = _this2.propsData.dataUnit[key];
6799 startData = startData.map(_this2.convertToMarksArray.bind(_this2, computedStyle, endUnit, key));
6800 style[cssName] = startData;
6801 } else {
6802 // 计算单位
6803 endUnit = _this2.propsData.dataUnit[cssName];
6804 startUnit = startData.toString().replace(/[^a-z|%]/g, '');
6805 if (endUnit !== startUnit) {
6806 startData = Object(__WEBPACK_IMPORTED_MODULE_2__util_js__["h" /* startConvertToEndUnit */])(_this2.target, computedStyle, cssName, parseFloat(startData), startUnit, endUnit, fixed);
6807 }
6808 style[cssName] = parseFloat(startData || 0);
6809 }
6810 });
6811 this.start = style;
6812 return style;
6813};
6814p.setArrayRatio = function (ratio, start, vars, unit, type) {
6815 if (type === 'color' && start.length === 4 && vars.length === 3) {
6816 vars[3] = 1;
6817 }
6818 var startInset = start.indexOf('inset') >= 0;
6819 var endInset = vars.indexOf('inset') >= 0;
6820 if (startInset && !endInset || endInset && !startInset) {
6821 throw console.error('Error: "box-shadow" inset have to exist');
6822 }
6823 var length = endInset ? 9 : 8;
6824 if (start.length === length && vars.length === length - 1) {
6825 vars.splice(3, 0, 0);
6826 unit.splice(3, 0, '');
6827 } else if (vars.length === length && start.length === length - 1) {
6828 start.splice(3, 0, 0);
6829 }
6830 var _vars = vars.map(function (endData, i) {
6831 var startIsAlpha = type === 'color' && i === 3 && !start[i] ? 1 : 0;
6832 var startData = typeof start[i] === 'number' ? start[i] : startIsAlpha;
6833 if (typeof endData === 'string') {
6834 return endData;
6835 }
6836 return (endData - startData) * ratio + startData + (unit[i] || 0);
6837 });
6838 if (type === 'color') {
6839 return Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["getColor"])(_vars);
6840 } else if (type === 'shadow') {
6841 var l = _vars.length === length ? 4 : 3;
6842 var s = _vars.slice(0, l).map(function (item) {
6843 if (typeof item === 'number') {
6844 return item + 'px';
6845 }
6846 return item;
6847 });
6848 var c = _vars.slice(l, endInset ? _vars.length - 1 : _vars.length);
6849 var color = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["getColor"])(c);
6850 return (s.join(' ') + ' ' + color + ' ' + (endInset ? 'inset' : '')).trim();
6851 }
6852 return _vars;
6853};
6854
6855p.setRatio = function (ratio, tween, computedStyle) {
6856 var _this3 = this;
6857
6858 tween.style = tween.style || {};
6859 if (this.start.transform) {
6860 tween.style.transform = tween.style.transform || __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, this.start.transform);
6861 }
6862 var style = this.target.style;
6863 Object.keys(this.propsData.data).forEach(function (key) {
6864 var _isTransform = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["isTransform"])(key) === 'transform';
6865 var startVars = _isTransform ? _this3.start.transform[key] : _this3.start[key];
6866 var endVars = _this3.propsData.data[key];
6867 var unit = _this3.propsData.dataUnit[key];
6868 var count = _this3.propsData.dataCount[key];
6869 if (key in __WEBPACK_IMPORTED_MODULE_3__plugins__["a" /* default */]) {
6870 _this3.propsData.data[key].setRatio(ratio, tween, computedStyle);
6871 if (key === 'bezier') {
6872 style[_this3.transform] = Object(__WEBPACK_IMPORTED_MODULE_2__util_js__["d" /* getTransformValue */])(tween.style.transform);
6873 } else {
6874 Object.keys(tween.style).forEach(function (css) {
6875 style[css] = tween.style[css];
6876 });
6877 }
6878 return;
6879 } else if (_isTransform) {
6880 if (unit && unit.match(/%|vw|vh|em|rem/i)) {
6881 startVars = parseFloat(_this3.start.transform[key]);
6882 if (count.charAt(1) === '=') {
6883 tween.style.transform[key] = startVars + endVars * ratio + unit;
6884 } else {
6885 tween.style.transform[key] = (endVars - startVars) * ratio + startVars + unit;
6886 }
6887 } else if (key === 'scale') {
6888 var xStart = _this3.start.transform.scaleX;
6889 var yStart = _this3.start.transform.scaleY;
6890 if (count.charAt(1) === '=') {
6891 tween.style.transform.scaleX = xStart + endVars * ratio;
6892 tween.style.transform.scaleY = yStart + endVars * ratio;
6893 } else {
6894 tween.style.transform.scaleX = (endVars - xStart) * ratio + xStart;
6895 tween.style.transform.scaleY = (endVars - yStart) * ratio + yStart;
6896 }
6897 } else if (count.charAt(1) === '=') {
6898 tween.style.transform[key] = startVars + endVars * ratio;
6899 } else {
6900 tween.style.transform[key] = (endVars - startVars) * ratio + startVars;
6901 }
6902 style[_this3.transform] = Object(__WEBPACK_IMPORTED_MODULE_2__util_js__["d" /* getTransformValue */])(tween.style.transform);
6903 if (computedStyle) {
6904 computedStyle.transformSVG = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["createMatrix"])(style[_this3.transform]).toString();
6905 }
6906 return;
6907 } else if (Array.isArray(endVars)) {
6908 var _type = _this3.propsData.dataType[key];
6909 tween.style[key] = _this3.setArrayRatio(ratio, startVars, endVars, unit, _type);
6910 if (_type === 'string') {
6911 tween.style[key] = tween.style[key].join(_this3.propsData.dataSplitStr[key]);
6912 }
6913 } else {
6914 var styleUnit = Object(__WEBPACK_IMPORTED_MODULE_1_style_utils__["stylesToCss"])(key, 0);
6915 styleUnit = typeof styleUnit === 'number' ? '' : styleUnit.replace(/[^a-z|%]/g, '');
6916 unit = unit || (__WEBPACK_IMPORTED_MODULE_1_style_utils__["cssList"].filter.indexOf(key) >= 0 ? '' : styleUnit);
6917 if (typeof endVars === 'string') {
6918 tween.style[key] = endVars;
6919 } else if (count.charAt(1) === '=') {
6920 tween.style[key] = startVars + endVars * ratio + unit;
6921 } else {
6922 var value = (endVars - startVars) * ratio + startVars;
6923 tween.style[key] = unit ? '' + value + unit : value;
6924 }
6925 }
6926 if (__WEBPACK_IMPORTED_MODULE_1_style_utils__["cssList"].filter.indexOf(key) >= 0) {
6927 if (!_this3.filterObject) {
6928 return;
6929 }
6930 _this3.filterObject[key] = tween.style[key];
6931 var filterStyle = '';
6932 Object.keys(_this3.filterObject).forEach(function (filterKey) {
6933 filterStyle += ' ' + filterKey + '(' + _this3.filterObject[filterKey] + ')';
6934 });
6935 style[_this3.filterName] = filterStyle.trim();
6936 return;
6937 }
6938 style[key] = tween.style[key];
6939 });
6940};
6941/* harmony default export */ __webpack_exports__["a"] = (StylePlugin);
6942
6943/***/ }),
6944/* 118 */
6945/***/ (function(module, exports, __webpack_require__) {
6946
6947/* WEBPACK VAR INJECTION */(function(global) {var now = __webpack_require__(120)
6948 , root = typeof window === 'undefined' ? global : window
6949 , vendors = ['moz', 'webkit']
6950 , suffix = 'AnimationFrame'
6951 , raf = root['request' + suffix]
6952 , caf = root['cancel' + suffix] || root['cancelRequest' + suffix]
6953
6954for(var i = 0; !raf && i < vendors.length; i++) {
6955 raf = root[vendors[i] + 'Request' + suffix]
6956 caf = root[vendors[i] + 'Cancel' + suffix]
6957 || root[vendors[i] + 'CancelRequest' + suffix]
6958}
6959
6960// Some versions of FF have rAF but not cAF
6961if(!raf || !caf) {
6962 var last = 0
6963 , id = 0
6964 , queue = []
6965 , frameDuration = 1000 / 60
6966
6967 raf = function(callback) {
6968 if(queue.length === 0) {
6969 var _now = now()
6970 , next = Math.max(0, frameDuration - (_now - last))
6971 last = next + _now
6972 setTimeout(function() {
6973 var cp = queue.slice(0)
6974 // Clear queue here to prevent
6975 // callbacks from appending listeners
6976 // to the current frame's queue
6977 queue.length = 0
6978 for(var i = 0; i < cp.length; i++) {
6979 if(!cp[i].cancelled) {
6980 try{
6981 cp[i].callback(last)
6982 } catch(e) {
6983 setTimeout(function() { throw e }, 0)
6984 }
6985 }
6986 }
6987 }, Math.round(next))
6988 }
6989 queue.push({
6990 handle: ++id,
6991 callback: callback,
6992 cancelled: false
6993 })
6994 return id
6995 }
6996
6997 caf = function(handle) {
6998 for(var i = 0; i < queue.length; i++) {
6999 if(queue[i].handle === handle) {
7000 queue[i].cancelled = true
7001 }
7002 }
7003 }
7004}
7005
7006module.exports = function(fn) {
7007 // Wrap in a new function to prevent
7008 // `cancel` potentially being assigned
7009 // to the native rAF function
7010 return raf.call(root, fn)
7011}
7012module.exports.cancel = function() {
7013 caf.apply(root, arguments)
7014}
7015module.exports.polyfill = function(object) {
7016 if (!object) {
7017 object = root;
7018 }
7019 object.requestAnimationFrame = raf
7020 object.cancelAnimationFrame = caf
7021}
7022
7023/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(119)))
7024
7025/***/ }),
7026/* 119 */
7027/***/ (function(module, exports) {
7028
7029var g;
7030
7031// This works in non-strict mode
7032g = (function() {
7033 return this;
7034})();
7035
7036try {
7037 // This works if eval is allowed (see CSP)
7038 g = g || Function("return this")() || (1,eval)("this");
7039} catch(e) {
7040 // This works if the window reference is available
7041 if(typeof window === "object")
7042 g = window;
7043}
7044
7045// g can still be undefined, but nothing to do about it...
7046// We return undefined, instead of nothing here, so it's
7047// easier to handle this case. if(!global) { ...}
7048
7049module.exports = g;
7050
7051
7052/***/ }),
7053/* 120 */
7054/***/ (function(module, exports, __webpack_require__) {
7055
7056/* WEBPACK VAR INJECTION */(function(process) {// Generated by CoffeeScript 1.12.2
7057(function() {
7058 var getNanoSeconds, hrtime, loadTime, moduleLoadTime, nodeLoadTime, upTime;
7059
7060 if ((typeof performance !== "undefined" && performance !== null) && performance.now) {
7061 module.exports = function() {
7062 return performance.now();
7063 };
7064 } else if ((typeof process !== "undefined" && process !== null) && process.hrtime) {
7065 module.exports = function() {
7066 return (getNanoSeconds() - nodeLoadTime) / 1e6;
7067 };
7068 hrtime = process.hrtime;
7069 getNanoSeconds = function() {
7070 var hr;
7071 hr = hrtime();
7072 return hr[0] * 1e9 + hr[1];
7073 };
7074 moduleLoadTime = getNanoSeconds();
7075 upTime = process.uptime() * 1e9;
7076 nodeLoadTime = moduleLoadTime - upTime;
7077 } else if (Date.now) {
7078 module.exports = function() {
7079 return Date.now() - loadTime;
7080 };
7081 loadTime = Date.now();
7082 } else {
7083 module.exports = function() {
7084 return new Date().getTime() - loadTime;
7085 };
7086 loadTime = new Date().getTime();
7087 }
7088
7089}).call(this);
7090
7091//# sourceMappingURL=performance-now.js.map
7092
7093/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(17)))
7094
7095/***/ }),
7096/* 121 */
7097/***/ (function(module, __webpack_exports__, __webpack_require__) {
7098
7099"use strict";
7100/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__ = __webpack_require__(0);
7101/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__);
7102/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck__ = __webpack_require__(8);
7103/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck__);
7104/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn__ = __webpack_require__(9);
7105/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn__);
7106/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass__ = __webpack_require__(10);
7107/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass__);
7108/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits__ = __webpack_require__(11);
7109/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits__);
7110/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_react__ = __webpack_require__(1);
7111/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_react__);
7112/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_prop_types__ = __webpack_require__(5);
7113/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_prop_types__);
7114/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_react_lifecycles_compat__ = __webpack_require__(22);
7115/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__TweenOne__ = __webpack_require__(60);
7116/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__util__ = __webpack_require__(21);
7117
7118
7119
7120
7121
7122
7123
7124
7125
7126
7127
7128
7129function noop() {}
7130
7131var TweenOneGroup = function (_Component) {
7132 __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits___default()(TweenOneGroup, _Component);
7133
7134 __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass___default()(TweenOneGroup, null, [{
7135 key: 'getDerivedStateFromProps',
7136 value: function getDerivedStateFromProps(props, _ref) {
7137 var prevProps = _ref.prevProps,
7138 $self = _ref.$self;
7139
7140 var nextState = {
7141 prevProps: props
7142 };
7143 if (prevProps) {
7144 var nextChildren = Object(__WEBPACK_IMPORTED_MODULE_9__util__["j" /* toArrayChildren */])(props.children);
7145 if (Object.keys($self.isTween).length && !props.exclusive) {
7146 $self.animQueue.push(nextChildren);
7147 return;
7148 }
7149 var currentChildren = Object(__WEBPACK_IMPORTED_MODULE_9__util__["j" /* toArrayChildren */])($self.currentChildren);
7150 nextState.children = $self.changeChildren(nextChildren, currentChildren);
7151 }
7152 return nextState; // eslint-disable-line
7153 }
7154 }]);
7155
7156 function TweenOneGroup(props) {
7157 __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck___default()(this, TweenOneGroup);
7158
7159 var _this = __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn___default()(this, (TweenOneGroup.__proto__ || Object.getPrototypeOf(TweenOneGroup)).call(this, props));
7160
7161 _initialiseProps.call(_this);
7162
7163 _this.keysToEnter = [];
7164 _this.keysToLeave = [];
7165 _this.saveTweenTag = {};
7166 _this.onEnterBool = false;
7167 _this.animQueue = [];
7168 _this.isTween = {};
7169 // 第一进入,appear 为 true 时默认用 enter 或 tween-one 上的效果
7170 var children = Object(__WEBPACK_IMPORTED_MODULE_9__util__["j" /* toArrayChildren */])(Object(__WEBPACK_IMPORTED_MODULE_9__util__["c" /* getChildrenFromProps */])(_this.props));
7171 _this.currentChildren = Object(__WEBPACK_IMPORTED_MODULE_9__util__["j" /* toArrayChildren */])(Object(__WEBPACK_IMPORTED_MODULE_9__util__["c" /* getChildrenFromProps */])(_this.props));
7172 _this.state = {
7173 children: children,
7174 $self: _this
7175 };
7176 return _this;
7177 }
7178
7179 __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass___default()(TweenOneGroup, [{
7180 key: 'componentDidMount',
7181 value: function componentDidMount() {
7182 this.onEnterBool = true;
7183 }
7184 }, {
7185 key: 'changeChildren',
7186 value: function changeChildren(nextChildren, currentChildren) {
7187 var _this2 = this;
7188
7189 var newChildren = Object(__WEBPACK_IMPORTED_MODULE_9__util__["e" /* mergeChildren */])(currentChildren, nextChildren);
7190 this.keysToEnter = [];
7191 this.keysToLeave = [];
7192 nextChildren.forEach(function (c) {
7193 if (!c) {
7194 return;
7195 }
7196 var key = c.key;
7197 var hasPrev = Object(__WEBPACK_IMPORTED_MODULE_9__util__["b" /* findChildInChildrenByKey */])(currentChildren, key);
7198 // 如果当前 key 已存在 saveTweenTag 里,,刷新 child;
7199 if (_this2.saveTweenTag[key]) {
7200 _this2.saveTweenTag[key] = __WEBPACK_IMPORTED_MODULE_5_react___default.a.cloneElement(_this2.saveTweenTag[key], {}, c);
7201 }
7202 if (!hasPrev && key) {
7203 _this2.keysToEnter.push(key);
7204 }
7205 });
7206
7207 currentChildren.forEach(function (c) {
7208 if (!c) {
7209 return;
7210 }
7211 var key = c.key;
7212 var hasNext = Object(__WEBPACK_IMPORTED_MODULE_9__util__["b" /* findChildInChildrenByKey */])(nextChildren, key);
7213 if (!hasNext && key) {
7214 _this2.keysToLeave.push(key);
7215 delete _this2.saveTweenTag[key];
7216 }
7217 });
7218 this.currentChildren = newChildren;
7219 return newChildren;
7220 }
7221 }, {
7222 key: 'render',
7223 value: function render() {
7224 var childrenToRender = this.getChildrenToRender(this.state.children);
7225 if (!this.props.component) {
7226 return childrenToRender[0] || null;
7227 }
7228 var componentProps = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, this.props);
7229 ['component', 'componentProps', 'appear', 'enter', 'leave', 'animatingClassName', 'onEnd', 'exclusive', 'resetStyle'].forEach(function (key) {
7230 return delete componentProps[key];
7231 });
7232 return Object(__WEBPACK_IMPORTED_MODULE_5_react__["createElement"])(this.props.component, __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, componentProps, this.props.componentProps), childrenToRender);
7233 }
7234 }]);
7235
7236 return TweenOneGroup;
7237}(__WEBPACK_IMPORTED_MODULE_5_react__["Component"]);
7238
7239var _initialiseProps = function _initialiseProps() {
7240 var _this3 = this;
7241
7242 this.onChange = function (animation, key, type, obj) {
7243 var length = Object(__WEBPACK_IMPORTED_MODULE_9__util__["a" /* dataToArray */])(animation).length;
7244 var tag = obj.target;
7245 var classIsSvg = typeof tag.className === 'object' && 'baseVal' in tag.className;
7246 var isEnter = type === 'enter' || type === 'appear';
7247 if (obj.mode === 'onStart') {
7248 if (classIsSvg) {
7249 tag.className.baseVal = _this3.setClassName(tag.className.baseVal, isEnter);
7250 } else {
7251 tag.className = _this3.setClassName(tag.className, isEnter);
7252 }
7253 } else if (obj.index === length - 1 && obj.mode === 'onComplete') {
7254 delete _this3.isTween[key];
7255 if (classIsSvg) {
7256 tag.className.baseVal = tag.className.baseVal.replace(_this3.props.animatingClassName[isEnter ? 0 : 1], '').trim();
7257 } else {
7258 tag.className = tag.className.replace(_this3.props.animatingClassName[isEnter ? 0 : 1], '').trim();
7259 }
7260 if (type === 'enter') {
7261 _this3.keysToEnter.splice(_this3.keysToEnter.indexOf(key), 1);
7262 if (!_this3.keysToEnter.length) {
7263 _this3.reAnimQueue();
7264 }
7265 } else if (type === 'leave') {
7266 _this3.keysToLeave.splice(_this3.keysToLeave.indexOf(key), 1);
7267 _this3.currentChildren = _this3.currentChildren.filter(function (child) {
7268 return key !== child.key;
7269 });
7270 if (!_this3.keysToLeave.length) {
7271 var currentChildrenKeys = _this3.currentChildren.map(function (item) {
7272 return item.key;
7273 });
7274 Object.keys(_this3.saveTweenTag).forEach(function ($key) {
7275 if (currentChildrenKeys.indexOf($key) === -1) {
7276 delete _this3.saveTweenTag[$key];
7277 }
7278 });
7279 _this3.setState({
7280 children: _this3.currentChildren
7281 }, _this3.reAnimQueue);
7282 }
7283 }
7284 var _obj = { key: key, type: type };
7285 _this3.props.onEnd(_obj);
7286 }
7287 };
7288
7289 this.setClassName = function (name, isEnter) {
7290 var className = name.replace(_this3.props.animatingClassName[isEnter ? 1 : 0], '').trim();
7291 if (className.indexOf(_this3.props.animatingClassName[isEnter ? 0 : 1]) === -1) {
7292 className = (className + ' ' + _this3.props.animatingClassName[isEnter ? 0 : 1]).trim();
7293 }
7294 return className;
7295 };
7296
7297 this.getTweenChild = function (child) {
7298 var props = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
7299
7300 var key = child.key;
7301 _this3.saveTweenTag[key] = __WEBPACK_IMPORTED_MODULE_5_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_8__TweenOne__["a" /* default */], __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, props, {
7302 key: key,
7303 component: null
7304 }), child);
7305 return _this3.saveTweenTag[key];
7306 };
7307
7308 this.getCoverAnimation = function (child, i, type) {
7309 var animation = void 0;
7310 animation = type === 'leave' ? _this3.props.leave : _this3.props.enter;
7311 if (type === 'appear') {
7312 var appear = Object(__WEBPACK_IMPORTED_MODULE_9__util__["k" /* transformArguments */])(_this3.props.appear, child.key, i);
7313 animation = appear && _this3.props.enter || null;
7314 }
7315 var animate = Object(__WEBPACK_IMPORTED_MODULE_9__util__["k" /* transformArguments */])(animation, child.key, i);
7316 var onChange = _this3.onChange.bind(_this3, animate, child.key, type);
7317 var props = {
7318 key: child.key,
7319 animation: animate,
7320 onChange: onChange,
7321 resetStyle: _this3.props.resetStyle
7322 };
7323 if (_this3.keysToEnter.concat(_this3.keysToLeave).indexOf(child.key) >= 0 || !_this3.onEnterBool && animation) {
7324 if (!_this3.saveTweenTag[child.key]) {
7325 _this3.isTween[child.key] = type;
7326 }
7327 }
7328 var children = _this3.getTweenChild(child, props);
7329 return children;
7330 };
7331
7332 this.getChildrenToRender = function (children) {
7333 return children.map(function (child, i) {
7334 if (!child || !child.key) {
7335 return child;
7336 }
7337 var key = child.key;
7338
7339 if (_this3.keysToLeave.indexOf(key) >= 0) {
7340 return _this3.getCoverAnimation(child, i, 'leave');
7341 } else if ((_this3.keysToEnter.indexOf(key) >= 0 || _this3.isTween[key] && _this3.keysToLeave.indexOf(key) === -1) && !(_this3.isTween[key] === 'enter' && _this3.saveTweenTag[key])) {
7342 /**
7343 * 1. 在 key 在 enter 里。
7344 * 2. 出场未结束,触发进场, this.isTween[key] 为 leave, key 在 enter 里。
7345 * 3. 状态为 enter 且 tweenTag 里有值时,不执行重载动画属性,直接调用 tweenTag 里的。
7346 */
7347 return _this3.getCoverAnimation(child, i, 'enter');
7348 } else if (!_this3.onEnterBool) {
7349 return _this3.getCoverAnimation(child, i, 'appear');
7350 }
7351 return _this3.saveTweenTag[key];
7352 });
7353 };
7354
7355 this.reAnimQueue = function () {
7356 if (!Object.keys(_this3.isTween).length && _this3.animQueue.length) {
7357 var children = _this3.changeChildren(_this3.animQueue[_this3.animQueue.length - 1], _this3.state.children);
7358 _this3.setState({
7359 children: children
7360 });
7361 _this3.animQueue = [];
7362 }
7363 };
7364};
7365
7366TweenOneGroup.propTypes = {
7367 component: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
7368 componentProps: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.object,
7369 children: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
7370 style: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.object,
7371 appear: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.bool,
7372 enter: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
7373 leave: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.any,
7374 animatingClassName: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.array,
7375 onEnd: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.func,
7376 resetStyle: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.bool,
7377 exclusive: __WEBPACK_IMPORTED_MODULE_6_prop_types___default.a.bool
7378};
7379
7380TweenOneGroup.defaultProps = {
7381 component: 'div',
7382 componentProps: {},
7383 appear: true,
7384 animatingClassName: ['tween-one-entering', 'tween-one-leaving'],
7385 enter: { x: 50, opacity: 0, type: 'from' },
7386 leave: { x: -50, opacity: 0 },
7387 onEnd: noop,
7388 resetStyle: true,
7389 exclusive: false
7390};
7391TweenOneGroup.isTweenOneGroup = true;
7392/* harmony default export */ __webpack_exports__["a"] = (Object(__WEBPACK_IMPORTED_MODULE_7_react_lifecycles_compat__["a" /* polyfill */])(TweenOneGroup));
7393
7394/***/ }),
7395/* 122 */
7396/***/ (function(module, __webpack_exports__, __webpack_require__) {
7397
7398"use strict";
7399/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_objectWithoutProperties__ = __webpack_require__(47);
7400/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_objectWithoutProperties___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_objectWithoutProperties__);
7401/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_extends__ = __webpack_require__(0);
7402/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_extends___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_extends__);
7403/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_classCallCheck__ = __webpack_require__(8);
7404/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_classCallCheck___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_classCallCheck__);
7405/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn__ = __webpack_require__(9);
7406/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn__);
7407/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_createClass__ = __webpack_require__(10);
7408/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_createClass___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_createClass__);
7409/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_babel_runtime_helpers_inherits__ = __webpack_require__(11);
7410/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_babel_runtime_helpers_inherits___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_babel_runtime_helpers_inherits__);
7411/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_react__ = __webpack_require__(1);
7412/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_react__);
7413/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_prop_types__ = __webpack_require__(5);
7414/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_prop_types__);
7415/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_dom__ = __webpack_require__(28);
7416/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8_react_dom__);
7417/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_react_lifecycles_compat__ = __webpack_require__(22);
7418/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__ = __webpack_require__(45);
7419/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11_tween_functions__ = __webpack_require__(63);
7420/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11_tween_functions___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_11_tween_functions__);
7421/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12_style_utils__ = __webpack_require__(29);
7422/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12_style_utils___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_12_style_utils__);
7423/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__BgElement__ = __webpack_require__(123);
7424/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__utils__ = __webpack_require__(18);
7425/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__anim__ = __webpack_require__(30);
7426
7427
7428
7429
7430
7431
7432
7433
7434
7435
7436
7437
7438
7439
7440
7441
7442
7443
7444function noop() {}
7445
7446var Element = function (_Component) {
7447 __WEBPACK_IMPORTED_MODULE_5_babel_runtime_helpers_inherits___default()(Element, _Component);
7448
7449 __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_createClass___default()(Element, null, [{
7450 key: 'getDerivedStateFromProps',
7451 value: function getDerivedStateFromProps(props, _ref) {
7452 var prevProps = _ref.prevProps,
7453 $self = _ref.$self;
7454
7455 var nextState = {
7456 prevProps: props
7457 };
7458 if (prevProps && props !== prevProps) {
7459 if ($self.tickerId !== -1) {
7460 __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].clear($self.tickerId);
7461 $self.tickerId = -1;
7462 }
7463 var followParallax = props.followParallax;
7464 if ($self.followParallax && !followParallax) {
7465 $self.reFollowParallax();
7466 } else {
7467 $self.followParallax = followParallax;
7468 }
7469 nextState.mouseMoveType = props.mouseMoveType;
7470 }
7471 return nextState;
7472 }
7473 }]);
7474
7475 function Element(props) {
7476 __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_classCallCheck___default()(this, Element);
7477
7478 var _this = __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_possibleConstructorReturn___default()(this, (Element.__proto__ || Object.getPrototypeOf(Element)).call(this, props));
7479
7480 _initialiseProps.call(_this);
7481
7482 _this.state = {
7483 show: props.show,
7484 $self: _this
7485 };
7486 _this.tickerId = -1;
7487 _this.enterMouse = null;
7488 _this.delayTimeout = null;
7489 _this.followParallax = props.followParallax;
7490 _this.transform = Object(__WEBPACK_IMPORTED_MODULE_12_style_utils__["checkStyleName"])('transform');
7491 return _this;
7492 }
7493
7494 __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_createClass___default()(Element, [{
7495 key: 'componentDidMount',
7496 value: function componentDidMount() {
7497 this.dom = __WEBPACK_IMPORTED_MODULE_8_react_dom___default.a.findDOMNode(this);
7498 }
7499 }, {
7500 key: 'componentDidUpdate',
7501 value: function componentDidUpdate() {
7502 if (this.followParallax) {
7503 this.doms = this.followParallax.data.map(function (item) {
7504 return document.getElementById(item.id);
7505 });
7506 }
7507 }
7508 }, {
7509 key: 'componentWillUnmount',
7510 value: function componentWillUnmount() {
7511 __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].clear(this.timeoutID);
7512 __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].clear(this.delayTimeout);
7513 this.delayTimeout = -1;
7514 this.timeoutID = -1;
7515 }
7516 }, {
7517 key: 'render',
7518 value: function render() {
7519 var props = __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_extends___default()({}, this.props, this.props.componentProps);
7520 var style = __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_extends___default()({}, props.style);
7521 var show = props.show;
7522
7523 style.display = show ? 'block' : 'none';
7524 style.position = 'absolute';
7525 style.width = '100%';
7526 if (this.props.mouseMoveType !== 'end') {
7527 style[this.transform] = '';
7528 }
7529 props.style = style;
7530 props.className = ('banner-anim-elem ' + (this.props.prefixCls || '')).trim();
7531 var bgElem = Object(__WEBPACK_IMPORTED_MODULE_14__utils__["f" /* toArrayChildren */])(this.props.children).filter(function (item) {
7532 return item && item.type.isBannerAnimBgElement;
7533 }).map(function (item) {
7534 return __WEBPACK_IMPORTED_MODULE_6_react___default.a.cloneElement(item, { show: props.show });
7535 });
7536 ['prefixCls', 'callBack', 'animType', 'duration', 'delay', 'ease', 'elemOffset', 'followParallax', 'show', 'type', 'direction', 'leaveChildHide', 'sync', 'ratio', 'mouseMoveType'].forEach(function (key) {
7537 return delete props[key];
7538 });
7539 if (this.state.show === show && !this.state.mouseMoveType || this.state.mouseMoveType === 'reChild') {
7540 props.animation = { x: 0, y: 0, type: 'set' };
7541 if (!show) {
7542 this.enterMouse = null;
7543 return __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["b" /* default */], props, bgElem);
7544 }
7545 if (this.props.followParallax) {
7546 props.onMouseMove = this.getFollowMouseMove();
7547 }
7548 return __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["b" /* default */], props, this.props.mouseMoveType === 'update' ? bgElem : this.getChildren());
7549 }
7550 return this.animChildren(props, style, bgElem);
7551 }
7552 }]);
7553
7554 return Element;
7555}(__WEBPACK_IMPORTED_MODULE_6_react__["Component"]);
7556
7557var _initialiseProps = function _initialiseProps() {
7558 var _this2 = this;
7559
7560 this.onMouseMove = function (e) {
7561 _this2.domRect = _this2.dom.getBoundingClientRect();
7562 _this2.enterMouse = _this2.enterMouse || { x: _this2.domRect.width / 2, y: _this2.domRect.height / 2 };
7563 _this2.domWH = {
7564 w: _this2.domRect.width,
7565 h: _this2.domRect.height
7566 };
7567 _this2.offsetTop = _this2.domRect.top + Object(__WEBPACK_IMPORTED_MODULE_14__utils__["b" /* currentScrollTop */])();
7568 _this2.offsetLeft = _this2.domRect.left + Object(__WEBPACK_IMPORTED_MODULE_14__utils__["a" /* currentScrollLeft */])();
7569 var mouseXY = {
7570 x: e.pageX - _this2.offsetLeft,
7571 y: e.pageY - _this2.offsetTop
7572 };
7573 _this2.setTicker(_this2.followParallax, mouseXY);
7574 };
7575
7576 this.setTicker = function (followParallax, mouseXY) {
7577 var callback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : noop;
7578
7579 __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].clear(_this2.tickerId);
7580 _this2.tickerId = 'bannerElementTicker' + (Date.now() + Math.random());
7581 var startFrame = __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].frame;
7582 var startX = _this2.enterMouse.x;
7583 var startY = _this2.enterMouse.y;
7584 var duration = followParallax.duration || 450;
7585 var easeFunc = __WEBPACK_IMPORTED_MODULE_11_tween_functions___default.a[followParallax.ease || 'easeOutQuad'];
7586 var start = typeof followParallax.minMove === 'number' ? followParallax.minMove : 0.08;
7587 __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].wake(_this2.tickerId, function () {
7588 var moment = (__WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].frame - startFrame) * __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].perFrame;
7589 var ratio = easeFunc(moment, start, 1, duration);
7590 _this2.enterMouse.x = startX + (mouseXY.x - startX) * ratio;
7591 _this2.enterMouse.y = startY + (mouseXY.y - startY) * ratio;
7592 _this2.setFollowStyle(_this2.domWH);
7593 if (moment >= duration) {
7594 __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].clear(_this2.tickerId);
7595 callback();
7596 }
7597 });
7598 };
7599
7600 this.getFollowMouseMove = function () {
7601 var onMouseMove = void 0;
7602 if (_this2.followParallax) {
7603 if (_this2.followParallax.delay) {
7604 onMouseMove = !_this2.delayTimeout ? null : _this2.state.onMouseMove;
7605 _this2.delayTimeout = _this2.delayTimeout || __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].timeout(function () {
7606 _this2.setState({
7607 onMouseMove: _this2.onMouseMove
7608 });
7609 }, _this2.followParallax.delay);
7610 } else {
7611 onMouseMove = _this2.onMouseMove;
7612 }
7613 }
7614 return onMouseMove;
7615 };
7616
7617 this.getFollowStyle = function (data, domWH) {
7618 var style = {};
7619 Object(__WEBPACK_IMPORTED_MODULE_14__utils__["c" /* dataToArray */])(data.type).forEach(function (type) {
7620 var mouseData = _this2.enterMouse.x;
7621 var domData = domWH.w;
7622 var value = data.value;
7623 if ((type.indexOf('y') >= 0 || type.indexOf('Y') >= 0) && type !== 'opacity') {
7624 mouseData = _this2.enterMouse.y;
7625 domData = domWH.h;
7626 }
7627 var d = (mouseData - domData / 2) / (domData / 2) * value;
7628 var _type = Object(__WEBPACK_IMPORTED_MODULE_12_style_utils__["getGsapType"])(type);
7629 var cssName = Object(__WEBPACK_IMPORTED_MODULE_12_style_utils__["isConvert"])(_type);
7630 if (cssName === 'transform') {
7631 var transform = Object(__WEBPACK_IMPORTED_MODULE_12_style_utils__["checkStyleName"])('transform');
7632 style[transform] = style[transform] || {};
7633 style[transform][_type] = Object(__WEBPACK_IMPORTED_MODULE_12_style_utils__["stylesToCss"])(_type, d).trim();
7634 } else if (cssName === 'filter') {
7635 var filter = Object(__WEBPACK_IMPORTED_MODULE_12_style_utils__["checkStyleName"])('filter');
7636 style[filter] = style[filter] || {};
7637 style[filter][_type] = Object(__WEBPACK_IMPORTED_MODULE_12_style_utils__["stylesToCss"])(_type, d).trim();
7638 } else {
7639 style[cssName] = Object(__WEBPACK_IMPORTED_MODULE_12_style_utils__["stylesToCss"])(_type, d).trim();
7640 }
7641 });
7642 return style;
7643 };
7644
7645 this.setFollowStyle = function (domWH) {
7646 _this2.doms.forEach(function (item, i) {
7647 if (!item) {
7648 return;
7649 }
7650 var data = _this2.followParallax.data[i];
7651 var style = _this2.getFollowStyle(data, domWH);
7652 Object.keys(style).forEach(function (key) {
7653 if (typeof style[key] === 'object') {
7654 var styleStr = '';
7655 Object.keys(style[key]).forEach(function (_key) {
7656 styleStr += (' ' + _key + '(' + style[key][_key] + ')').trim();
7657 });
7658 item.style[key] = styleStr;
7659 return;
7660 }
7661 item.style[key] = key.indexOf('backgroundPosition') >= 0 ? 'calc(' + (data.bgPosition || '0%') + ' + ' + style[key] + ' )' : style[key];
7662 });
7663 });
7664 };
7665
7666 this.getChildren = function () {
7667 return Object(__WEBPACK_IMPORTED_MODULE_14__utils__["f" /* toArrayChildren */])(_this2.props.children).map(function (item, i) {
7668 if (item && item.type === __WEBPACK_IMPORTED_MODULE_13__BgElement__["a" /* default */]) {
7669 return __WEBPACK_IMPORTED_MODULE_6_react___default.a.cloneElement(item, { show: _this2.state.show });
7670 }
7671 return _this2.useTagComp ? Object(__WEBPACK_IMPORTED_MODULE_14__utils__["d" /* setAnimCompToTagComp */])(item, i) : item;
7672 });
7673 };
7674
7675 this.reFollowParallax = function () {
7676 if (!_this2.domRect) {
7677 return;
7678 }
7679 _this2.setTicker(_this2.followParallax, {
7680 x: _this2.domRect.width / 2 - _this2.offsetLeft,
7681 y: _this2.domRect.height / 2 - _this2.offsetTop
7682 }, function () {
7683 _this2.followParallax = null;
7684 });
7685 };
7686
7687 this.animEnd = function () {
7688 var type = _this2.state.show ? 'enter' : 'leave';
7689 _this2.props.callBack(type);
7690 _this2.setState(function (_, props) {
7691 return { show: props.show, mouseMoveType: null };
7692 });
7693 };
7694
7695 this.animChildren = function (props, style, bgElem) {
7696 var _props = _this2.props,
7697 elemOffset = _props.elemOffset,
7698 leaveChildHide = _props.leaveChildHide,
7699 ratio = _props.ratio,
7700 currentAnimType = _props.animType,
7701 direction = _props.direction,
7702 mouseMoveType = _props.mouseMoveType,
7703 ease = _props.ease,
7704 duration = _props.duration,
7705 delay = _props.delay,
7706 show = _props.show,
7707 sync = _props.sync,
7708 component = _props.component;
7709
7710 if (_this2.tickerId) {
7711 __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].clear(_this2.tickerId);
7712 }
7713 if (_this2.delayTimeout) {
7714 __WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["c" /* ticker */].clear(_this2.delayTimeout);
7715 _this2.delayTimeout = null;
7716 }
7717 style.display = 'block';
7718
7719 props.component = component;
7720 style.zIndex = show ? 1 : 0;
7721 var type = show ? 'enter' : 'leave';
7722 _this2.useTagComp = (currentAnimType === __WEBPACK_IMPORTED_MODULE_15__anim__["a" /* default */].gridBar || currentAnimType === __WEBPACK_IMPORTED_MODULE_15__anim__["a" /* default */].grid) && (show === _this2.state.show || _this2.state.show && !show);
7723 // 状态没改,锁定 children
7724 props.children = !sync && (show && show !== _this2.state.show || !show && !_this2.state.show) ? bgElem : _this2.getChildren();
7725 var childrenToRender = __WEBPACK_IMPORTED_MODULE_6_react___default.a.createElement(__WEBPACK_IMPORTED_MODULE_10_rc_tween_one__["b" /* default */], props);
7726 var $ratio = mouseMoveType === 'end' && ratio <= 0.3 ? 1 - ratio : ratio;
7727 var tag = currentAnimType(childrenToRender, type, direction, {
7728 ease: ease,
7729 duration: duration,
7730 delay: delay,
7731 onComplete: _this2.animEnd
7732 }, elemOffset, leaveChildHide, $ratio, _this2.state.mouseMoveType === 'update');
7733
7734 var tagProps = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_objectWithoutProperties___default()(tag.props, []);
7735
7736 if (tagProps.animation) {
7737 tagProps.moment = (tagProps.animation.duration + tagProps.animation.delay) * $ratio || 0;
7738 tagProps.paused = _this2.state.mouseMoveType === 'update' || $ratio === 1;
7739 }
7740 return __WEBPACK_IMPORTED_MODULE_6_react___default.a.cloneElement(tag, tagProps);
7741 };
7742};
7743
7744Element.propTypes = {
7745 children: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.any,
7746 style: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.object,
7747 prefixCls: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.string,
7748 component: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.any,
7749 elemOffset: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.object,
7750 type: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.string,
7751 animType: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.func,
7752 ease: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.string,
7753 duration: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.number,
7754 delay: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.number,
7755 direction: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.string,
7756 callBack: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.func,
7757 followParallax: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.any,
7758 show: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.bool,
7759 leaveChildHide: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.bool,
7760 sync: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.bool,
7761 ratio: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.number,
7762 mouseMoveType: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.string,
7763 componentProps: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.object
7764};
7765Element.defaultProps = {
7766 component: 'div',
7767 componentProps: {},
7768 callBack: noop,
7769 delay: 0
7770};
7771
7772Element.BgElement = Object(__WEBPACK_IMPORTED_MODULE_9_react_lifecycles_compat__["a" /* polyfill */])(__WEBPACK_IMPORTED_MODULE_13__BgElement__["a" /* default */]);
7773Element.isBannerAnimElement = true;
7774/* harmony default export */ __webpack_exports__["a"] = (Object(__WEBPACK_IMPORTED_MODULE_9_react_lifecycles_compat__["a" /* polyfill */])(Element));
7775
7776/***/ }),
7777/* 123 */
7778/***/ (function(module, __webpack_exports__, __webpack_require__) {
7779
7780"use strict";
7781/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__ = __webpack_require__(0);
7782/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends__);
7783/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck__ = __webpack_require__(8);
7784/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck__);
7785/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn__ = __webpack_require__(9);
7786/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn__);
7787/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass__ = __webpack_require__(10);
7788/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass__);
7789/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits__ = __webpack_require__(11);
7790/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits__);
7791/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_react__ = __webpack_require__(1);
7792/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_react___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5_react__);
7793/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_react_dom__ = __webpack_require__(28);
7794/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_react_dom___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6_react_dom__);
7795/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_prop_types__ = __webpack_require__(5);
7796/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_prop_types___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7_prop_types__);
7797/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_rc_tween_one__ = __webpack_require__(45);
7798/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_style_utils__ = __webpack_require__(29);
7799/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_style_utils___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_9_style_utils__);
7800/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__utils__ = __webpack_require__(18);
7801/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__anim__ = __webpack_require__(30);
7802
7803
7804
7805
7806
7807
7808
7809
7810
7811
7812
7813
7814
7815var BgElement = function (_React$Component) {
7816 __WEBPACK_IMPORTED_MODULE_4_babel_runtime_helpers_inherits___default()(BgElement, _React$Component);
7817
7818 __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass___default()(BgElement, null, [{
7819 key: 'getDerivedStateFromProps',
7820 value: function getDerivedStateFromProps(props, _ref) {
7821 var prevProps = _ref.prevProps,
7822 $self = _ref.$self;
7823
7824 var nextState = {
7825 prevProps: props
7826 };
7827 if (prevProps && props !== prevProps) {
7828 if (props.show) {
7829 // 取 dom 在 render 之后;
7830 setTimeout(function () {
7831 if ($self.video && prevProps.videoResize && $self.videoLoad) {
7832 $self.onResize();
7833 }
7834 if (prevProps.scrollParallax) {
7835 $self.onScroll();
7836 }
7837 });
7838 }
7839 }
7840 return nextState;
7841 }
7842 }]);
7843
7844 function BgElement(props) {
7845 __WEBPACK_IMPORTED_MODULE_1_babel_runtime_helpers_classCallCheck___default()(this, BgElement);
7846
7847 var _this = __WEBPACK_IMPORTED_MODULE_2_babel_runtime_helpers_possibleConstructorReturn___default()(this, (BgElement.__proto__ || Object.getPrototypeOf(BgElement)).call(this, props));
7848
7849 _this.onScroll = function () {
7850 var scrollTop = Object(__WEBPACK_IMPORTED_MODULE_10__utils__["b" /* currentScrollTop */])();
7851 var domRect = _this.dom.parentNode.getBoundingClientRect();
7852 var offsetTop = domRect.top + scrollTop;
7853 var height = Math.max(domRect.height, Object(__WEBPACK_IMPORTED_MODULE_10__utils__["g" /* windowHeight */])());
7854 var elementShowHeight = scrollTop - offsetTop + height;
7855 var scale = elementShowHeight / (height + domRect.height);
7856 scale = scale || 0;
7857 scale = scale >= 1 ? 1 : scale;
7858 _this.tween.frame(scale * _this.scrollParallaxDuration);
7859 };
7860
7861 _this.onResize = function () {
7862 if (!_this.props.show) {
7863 return;
7864 }
7865 var domRect = _this.dom.getBoundingClientRect();
7866 var videoDomRect = _this.video.getBoundingClientRect();
7867 _this.videoLoad = true;
7868 var scale = void 0;
7869 var videoRect = {
7870 display: 'block',
7871 position: 'relative',
7872 top: 0,
7873 left: 0
7874 };
7875 if (domRect.width / domRect.height > videoDomRect.width / videoDomRect.height) {
7876 scale = domRect.width / videoDomRect.width;
7877 videoRect.width = domRect.width;
7878 videoRect.height = videoDomRect.height * scale;
7879 videoRect.top = -(videoRect.height - domRect.height) / 2;
7880 } else {
7881 scale = domRect.height / videoDomRect.height;
7882 videoRect.height = domRect.height;
7883 videoRect.width = videoDomRect.width * scale;
7884 videoRect.left = -(videoRect.width - domRect.width) / 2;
7885 }
7886
7887 Object.keys(videoRect).forEach(function (key) {
7888 _this.video.style[key] = Object(__WEBPACK_IMPORTED_MODULE_9_style_utils__["stylesToCss"])(key, videoRect[key]);
7889 });
7890 };
7891
7892 _this.videoLoadedData = function () {
7893 _this.onResize();
7894 if (window.addEventListener) {
7895 window.addEventListener('resize', _this.onResize);
7896 } else {
7897 window.attachEvent('onresize', _this.onResize);
7898 }
7899 };
7900
7901 _this.isVideo = Object(__WEBPACK_IMPORTED_MODULE_10__utils__["f" /* toArrayChildren */])(_this.props.children).some(function (item) {
7902 return item.type === 'video';
7903 });
7904 if (_this.isVideo) {
7905 // 如果是 video,删除 grid 系列,位置发生变化,重加载了 video;
7906 delete __WEBPACK_IMPORTED_MODULE_11__anim__["a" /* default */].grid;
7907 delete __WEBPACK_IMPORTED_MODULE_11__anim__["a" /* default */].gridBar;
7908 }
7909 if (_this.props.scrollParallax) {
7910 _this.scrollParallaxDuration = _this.props.scrollParallax.duration || 450;
7911 }
7912 _this.video = null;
7913 _this.videoLoad = false;
7914 _this.state = {
7915 $self: _this
7916 };
7917 return _this;
7918 }
7919
7920 __WEBPACK_IMPORTED_MODULE_3_babel_runtime_helpers_createClass___default()(BgElement, [{
7921 key: 'componentDidMount',
7922 value: function componentDidMount() {
7923 this.dom = __WEBPACK_IMPORTED_MODULE_6_react_dom___default.a.findDOMNode(this);
7924 if (!this.videoLoad) {
7925 if (this.video && this.props.videoResize) {
7926 this.video.onloadeddata = this.videoLoadedData;
7927 }
7928 }
7929 if (this.props.scrollParallax) {
7930 this.tween = new __WEBPACK_IMPORTED_MODULE_8_rc_tween_one__["a" /* Tween */](this.dom, [__WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({
7931 ease: 'linear' }, this.props.scrollParallax)]);
7932 this.tween.init();
7933 this.onScroll();
7934 if (window.addEventListener) {
7935 window.addEventListener('scroll', this.onScroll);
7936 } else {
7937 window.attachEvent('onscroll', this.onScroll);
7938 }
7939 }
7940 }
7941 }, {
7942 key: 'componentWillUnmount',
7943 value: function componentWillUnmount() {
7944 if (window.addEventListener) {
7945 window.removeEventListener('resize', this.onResize);
7946 window.removeEventListener('scroll', this.onScroll);
7947 } else {
7948 window.detachEvent('onresize', this.onResize);
7949 window.detachEvent('onscroll', this.onScroll);
7950 }
7951 }
7952 }, {
7953 key: 'render',
7954 value: function render() {
7955 var _this2 = this;
7956
7957 var props = __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, this.props, this.props.componentProps);
7958 ['videoResize', 'scrollParallax', 'scrollParallaxDuration', 'show', 'component', 'componentProps'].forEach(function (key) {
7959 return delete props[key];
7960 });
7961 if (this.isVideo && this.props.videoResize) {
7962 var children = Object(__WEBPACK_IMPORTED_MODULE_10__utils__["f" /* toArrayChildren */])(props.children).map(function (item, i) {
7963 return __WEBPACK_IMPORTED_MODULE_5_react___default.a.cloneElement(item, __WEBPACK_IMPORTED_MODULE_0_babel_runtime_helpers_extends___default()({}, item.props, { key: item.key || 'bg-video-' + i, ref: function ref(c) {
7964 _this2.video = c;
7965 if (typeof item.ref === 'function') {
7966 item.ref(c);
7967 }
7968 }
7969 }));
7970 });
7971 props.children = children.length === 1 ? children[0] : children;
7972 }
7973 return __WEBPACK_IMPORTED_MODULE_5_react___default.a.createElement(this.props.component, props);
7974 }
7975 }]);
7976
7977 return BgElement;
7978}(__WEBPACK_IMPORTED_MODULE_5_react___default.a.Component);
7979
7980/* harmony default export */ __webpack_exports__["a"] = (BgElement);
7981
7982
7983BgElement.propTypes = {
7984 className: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.string,
7985 style: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.object,
7986 children: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.any,
7987 component: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.any,
7988 videoResize: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.bool,
7989 scrollParallax: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.object,
7990 show: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.bool,
7991 componentProps: __WEBPACK_IMPORTED_MODULE_7_prop_types___default.a.object
7992};
7993
7994BgElement.defaultProps = {
7995 component: 'div',
7996 videoResize: true,
7997 componentProps: {}
7998};
7999
8000BgElement.isBannerAnimBgElement = true;
8001
8002/***/ })
8003/******/ ])["default"];
8004});
8005//# sourceMappingURL=rc-banner-anim.js.map
\No newline at end of file